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

Some commands with -s and full stack name flag require Pulumi.yaml #16226

Open
wclr opened this issue May 18, 2024 · 3 comments
Open

Some commands with -s and full stack name flag require Pulumi.yaml #16226

wclr opened this issue May 18, 2024 · 3 comments
Labels
area/cli UX of using the CLI (args, output, logs) kind/enhancement Improvements or new features

Comments

@wclr
Copy link

wclr commented May 18, 2024

What happened?

I'm using atomation api to launch pulumi programs, so I don't have Pulumi.yaml. Want to rename the stack, so I try rename command and get:

pulumi stack rename stack-new-name --stack user/proj/stack-name
error: no Pulumi.yaml project file found (searching upwards from ..). If you have not created a project yet, use `pulumi new` to do so: no project file found

Other commands too require the file, though some don't, for example, pulumi stack rm --stack user/proj/stack-name works without Pulumi.yaml.

Adding simple Pulumi.yaml with name and runtime works, but seems that it should not be required.

Example

pulumi stack rename stack-new-name --stack user/proj/stack-name2

Output of pulumi about

CLI
Version 3.97.0
Go Version go1.21.5
Go Compiler gc

Additional context

No response

Contributing

Vote on this issue by adding a 👍 reaction.
To contribute a fix for this issue, leave a comment (and link to your pull request, if you've opened one already).

@wclr wclr added kind/bug Some behavior is incorrect or out of spec needs-triage Needs attention from the triage team labels May 18, 2024
@wclr wclr changed the title Some commands with -s and full stack name flag still Pulumi.yaml Some commands with -s and full stack name flag require Pulumi.yaml May 18, 2024
@justinvp justinvp added area/cli UX of using the CLI (args, output, logs) kind/enhancement Improvements or new features and removed kind/bug Some behavior is incorrect or out of spec needs-triage Needs attention from the triage team labels May 26, 2024
@justinvp
Copy link
Member

Thanks for opening the issue, @wclr. We should be able to make rename work when the Pulumi.yaml file isn't found. We're really looking for the old Pulumi.<stack-name>.yaml containing the stack config so it can be renamed to the new stack name, but if we can't find it, it's reasonable to still allow the rename to work (though, we may want to emit a warning in that case).

@justinvp
Copy link
Member

Other commands too require the file

@wclr, do you recall the other commands?

@wclr
Copy link
Author

wclr commented May 28, 2024

Well, I think there are multiple, for example destroy, you should probably check them all.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/cli UX of using the CLI (args, output, logs) kind/enhancement Improvements or new features
Projects
None yet
Development

No branches or pull requests

2 participants