-
Notifications
You must be signed in to change notification settings - Fork 25
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
Tagging vms for efficient multi-instance commands #121
Conversation
Tags will now be expanded for commands with multiple instance support: * `cmd/delete.go` * `cmd/edit.go` * `cmd/publish.go` * `cmd/restart.go` * `cmd/start.go` * `cmd/stop.go` Format is: `alpine start +tagname` For example: ```bash $ alpine list NAME STATUS SSH PORTS ARCH PID TAGS mysql Stopped 2022 3306 aarch64 - daemon foobar Stopped 2023 aarch64 - daemon,dev $ alpine start +daemon ... starts mysql and foobar ... $ alpine stop mysql +dev ... stops mysql and foobar ... ```
Hey @idroz! This one wraps up my work on tagging VMs and then using commands with Requesting your review as there's a lot of code added, and probably some efficiency changes that could be made. If you have a chance, give it a quick test to make sure it works as you expect! Closes #95 |
Awesome - thanks @maxzinkus . Just got back into work mode, so will review all the goodies. |
Awesome! Hope you had a good break. I went ahead and added |
Tags will now be expanded for commands with multiple instance support: * `cmd/delete.go` * `cmd/edit.go` * `cmd/publish.go` * `cmd/restart.go` * `cmd/start.go` * `cmd/stop.go` Format is: `alpine start +tagname` For example: ```bash $ alpine list NAME STATUS SSH PORTS ARCH PID TAGS mysql Stopped 2022 3306 aarch64 - daemon foobar Stopped 2023 aarch64 - daemon,dev $ alpine start +daemon ... starts mysql and foobar ... $ alpine stop mysql +dev ... stops mysql and foobar ... ```
} | ||
|
||
return flags | ||
fmt.Println("launched: " + machineName) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cobra automatically adds completion for flags, as long as the user types the first -
e.g. alpine launch -[tab]
This looks awesome. I've tested
All work as expected. Code and doc changes look good. I think it's OK to be merged. |
Tags will now be expanded for commands with multiple instance support:
cmd/delete.go
cmd/edit.go
cmd/publish.go
cmd/restart.go
cmd/start.go
cmd/stop.go
Format is:
alpine start +tagname
For example: