Skip to content

fix: add entrypoint to Dockerfiles #1298

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

Merged
merged 1 commit into from
Aug 10, 2022
Merged

fix: add entrypoint to Dockerfiles #1298

merged 1 commit into from
Aug 10, 2022

Conversation

enocom
Copy link
Member

@enocom enocom commented Aug 5, 2022

Fixes #1296.

@enocom enocom requested a review from a team August 5, 2022 15:39
@enocom enocom changed the title fix: add entrypoint and cmd to Dockerfiles fix: add entrypoint to Dockerfiles Aug 5, 2022
@@ -30,3 +30,4 @@ FROM gcr.io/distroless/static:nonroot
COPY --from=build --chown=nonroot /go/src/cloudsql-proxy/cloud_sql_proxy /cloud_sql_proxy
# set the uid as an integer for compatibility with runAsNonRoot in Kubernetes
USER 65532
ENTRYPOINT ["/cloud_sql_proxy"]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Double check: this can be overridden in all of the usual environments (docker, podman, k8s, etc)?

Copy link
Collaborator

@hessjcg hessjcg Aug 10, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • Docker: yes docker run --entrypoint
  • Podman: yes, works like docker
  • K8s: yes "container": {"command": "/bin/sh"} container api doc

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @hessjcg.

@enocom enocom merged commit 1e31c96 into v2 Aug 10, 2022
@enocom enocom deleted the dockerfile-fixes branch August 10, 2022 20:45
enocom added a commit that referenced this pull request Aug 23, 2022
enocom added a commit that referenced this pull request Aug 29, 2022
enocom added a commit to GoogleCloudPlatform/alloydb-auth-proxy that referenced this pull request Sep 13, 2022
enocom added a commit to GoogleCloudPlatform/alloydb-auth-proxy that referenced this pull request Sep 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants