Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Container start fails because of missing S3_SERVICE variable #247

Closed
zc-devs opened this issue May 8, 2024 · 3 comments · Fixed by #248
Closed

Container start fails because of missing S3_SERVICE variable #247

zc-devs opened this issue May 8, 2024 · 3 comments · Fixed by #248
Assignees
Labels
bug Something isn't working

Comments

@zc-devs
Copy link
Contributor

zc-devs commented May 8, 2024

Describe the bug

Pod fails to run with error:

Required S3_SERVICE environment variable missing

while documentation says that there should be s3 default value.

BTW, documentation formatting is broken and there is no description as well.

To reproduce

Steps to reproduce the behavior:

  1. Start container with config
apiVersion: v1
kind: ConfigMap
metadata:
  name: ngs3gw
data:
  S3_STYLE: path
  S3_BUCKET_NAME: main
  S3_SERVER: minio.minio.svc.cluster.local
  S3_SERVER_PROTO: http
  S3_SERVER_PORT: "9000"
  S3_REGION: eu
  DEBUG: "true"
  AWS_SIGS_VERSION: "4"
  ALLOW_DIRECTORY_LIST: "true"
  1. View logs of Pod
  2. See error
/docker-entrypoint.sh: /docker-entrypoint.d/ is not empty, will attempt to perform configuration
/docker-entrypoint.sh: Looking for shell scripts in /docker-entrypoint.d/
/docker-entrypoint.sh: Launching /docker-entrypoint.d/00-check-for-required-env.sh
Required S3_SERVICE environment variable missing

Expected behavior

Container/Pod starts.

Your environment

  • ghcr.io/nginxinc/nginx-s3-gateway/nginx-oss-s3-gateway:unprivileged-oss-20240507
  • Target deployment platform: K3s
  • S3 backend implementation: MinIO

Additional context

Worked on unprivileged-oss-20240113. Works on unprivileged-oss-20240507 if S3_SERVICE: s3 is set.

@4141done
Copy link
Collaborator

4141done commented May 8, 2024

Thank you for flagging this @zc-devs and I really apologize for the oversight. I put together a quick fix and tested against the two s3 services we support. Can you check that this branch works as you expect? #248

@alessfg alessfg added the bug Something isn't working label May 8, 2024
@4141done
Copy link
Collaborator

4141done commented May 8, 2024

Thank you for flagging this @zc-devs and I really apologize for the oversight. I put together a quick fix and tested against the two s3 services we support. Can you check that this branch works as you expect? #248

I'm actually going to go ahead and merge so fewer people are bitten by this. Please let me know if the new image works for you.

@zc-devs
Copy link
Contributor Author

zc-devs commented May 9, 2024

@4141done, it works well. Thank you for a quick fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
3 participants