Hi, I have pulumi CLI issues. It does not list any...
# general
a
Hi, I have pulumi CLI issues. It does not list any of my stacks, even in the source code folder.
Copy code
➜  pulumi git:(main) ls -l
total 40
-rw-r--r--   1 lin  staff  4157 Sep 15 00:01 pom.xml
-rw-r--r--   1 lin  staff   336 Oct 16 11:51 Pulumi.deploy-infra.yaml
-rw-r--r--   1 lin  staff    95 May 20 00:39 Pulumi.yaml
drwxr-xr-x   4 lin  staff   128 May 20 00:39 src
drwxr-xr-x  11 lin  staff   352 Aug 18 00:24 target
➜  pulumi git:(main) pulumi stack ls
NAME  LAST UPDATE  RESOURCE COUNT  URL
➜  pulumi git:(main)
And I used to use this to list all my stacks, from any folder, but it stops working.
Copy code
pulumi stack ls -a -o my-org
The above command works OK in my CI pipelines, with API token. I am wondering if any CLI updates caused this issue.
Copy code
➜  pulumi git:(main) pulumi version
v3.203.0
m
Are you using a similar API token locally? I would suggest making sure you are logged in with an appropriate token. You can verify the login with
pulumi whoami -v
a
oh, how do I switch org?
when I use pulumi login, it opens chrome to auth,
it does not ask me to select which org
m
My experience is that when logging in via chrome, it will show all orgs that you have access to when running
pulumi whoami -v
Are you able to see the correct orgs when logging in the website?
a
yes, I can see all orgs, but in chrome, it does not ask me to choose which org
s
pulumi org set-default
might be helpful here. There's also
pulumi org get-default
.
In Pulumi Cloud, you can see the dropdown here:
a
Copy code
➜  pulumi git:(main)  pulumi login --default-org org-data-ai
Logged in to <http://pulumi.com|pulumi.com> as personal-org (<https://app.pulumi.com/personal-org>)
it just does not take my inputs
s
Your token is tied to your personal identity, and is valid (AFAIK) for all orgs of which you are a member. (From the CLI - logging into the Pulumi Cloud console is different.)
a
let me DM you
m
You can also try going to https://app.pulumi.com/user/settings/tokens and generating a new token and trying to log in with that to see if you get different behavior.
👀 1