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

Automate searching for environment & workspace by name #10

Open
anthonyangel opened this issue Sep 16, 2022 · 1 comment
Open

Automate searching for environment & workspace by name #10

anthonyangel opened this issue Sep 16, 2022 · 1 comment

Comments

@anthonyangel
Copy link

When making a change to an environment or a workspace I know the name of what I want to change, but I need to lookup the ID to pass into the CLI. If I could pass in the name then it would save manually looking this up.

I can do this with multiple commands at the moment, and pipe it together, but it feels like something which the CLI could handle for me.

Example of getting an environment ID from name, and then piping that back to the get-workspaces command, filtering just on the environment:

scalr list-environments | jq '.[] | select(.name=="demo-aa") | .id' | xargs -I {} scalr get-workspaces -filter[environment]={}
@buzzy
Copy link
Collaborator

buzzy commented Sep 19, 2022

Great feedback. I will have to think about how to implement this in the best way. It would make most sense to implement some kind of id-search attribute to be able to search by more than name and also for all commands and not only workspaces. Any ideas?

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

No branches or pull requests

2 participants