Skip to content

Instantly share code, notes, and snippets.

@4141done
Created November 27, 2023 19:57
Show Gist options
  • Save 4141done/de938b378cacb9a64b1c3ff08d9e4cf6 to your computer and use it in GitHub Desktop.
Save 4141done/de938b378cacb9a64b1c3ff08d9e4cf6 to your computer and use it in GitHub Desktop.
FROM nginxinc/nginx-s3-gateway
ENV S3_BUCKET_NAME "bucket"
ENV AWS_ACCESS_KEY_ID "aaaa"
ENV AWS_SECRET_ACCESS_KEY "aaaa"
ENV S3_SERVER "aaaaa"
ENV S3_SERVER_PORT "80"
ENV S3_SERVER_PROTO "http"
ENV S3_REGION "us-east-1"
ENV S3_STYLE "path"
ENV DEBUG "false"
ENV AWS_SIGS_VERSION "4"
ENV ALLOW_DIRECTORY_LIST "true"
ENV PROVIDE_INDEX_PAGE "true"
ENV NGINX_ENTRYPOINT_QUIET_LOGS "true"
COPY etc/nginx/conf.d /etc/nginx/conf.d
COPY . /var/uploads
## location: etc/nginx/conf.d/modifications.conf
location /foo/bar {
return 200 "This is the custom location";
}
## location: etc/nginx/conf.d/gateway/s3_server.conf
location /local/health {
return 200;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment