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

Remove the default entrypoint #176

Open
jkodroff opened this issue Nov 30, 2023 · 1 comment
Open

Remove the default entrypoint #176

jkodroff opened this issue Nov 30, 2023 · 1 comment
Labels
kind/enhancement Improvements or new features

Comments

@jkodroff
Copy link
Member

Hello!

  • Vote on this issue by adding a 👍 reaction
  • If you want to implement this feature, comment to let us know (we'll work with you on design, scheduling, etc.)

Issue details

We have a default entrypoint that calls pulumi, but in my limited experience with the Docker images, I am usually running other commands in the context of a CI/CD pipeline. (i.e. I am using pulumi/pulumi as the image in which I am running CI/CD.) Therefore, I find the default entrypoint not-especially-useful at best, and confusing at worst (because I didn't really expect the entrypoint to be set).

I think we should consider removing it in a future version. I know this would be a breaking change, so we'd likely need to wait until v4 of Pulumi itself as our container versions are aligned with the actual version of the Pulumi CLI. I would also not be heartbroken if we declined to make this change, since the downside of a breaking change may not be worth the upside of a more intuitive (IMO) interface to the container.

Affected area/feature

@jkodroff jkodroff added kind/enhancement Improvements or new features needs-triage Needs attention from the triage team labels Nov 30, 2023
@justinvp justinvp removed the needs-triage Needs attention from the triage team label Dec 3, 2023
@im7mortal
Copy link

As I understand it, the image is designed for tools like Google Cloud Build or scripts where arguments are passed directly.

For custom images, you can easily override the default entrypoint as follows:

ARG PULUMI_VERSION="latest"
FROM registry.hub.docker.com/pulumi/pulumi:$PULUMI_VERSION

# Override Pulumi's default entrypoint
ENTRYPOINT []

In the terminal, you can override the entrypoint using the --entrypoint flag:

docker run --entrypoint /bin/bash pulumi/pulumi

For example, in Google Cloud Build, you can use the entrypoint field:

steps:
- name: pulumi/pulumi:latest
  entrypoint: "/bin/bash"
  args: ["-c", "echo hello"]

I assume other build tools also have similar ways to override the entrypoint.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/enhancement Improvements or new features
Projects
None yet
Development

No branches or pull requests

3 participants