Closed maxzinkus closed 1 year ago
I think +tag_name
is cleaner than -t
because -t
will require reworking how commands are parsed across the board and breaks the pattern that's been established in how commands are run (command
, then optional args
, then vm target
-- IMO it's weird to have one optional arg that makes vm target
not apply). Thus,
TODO:
+tag_name
for VM name arguments and apply to all with the matching tagAutocompleteVMNames
to also suggest and complete tags
It would be useful to have a comma-separated string
Tags
field inconfig.yaml
for the following features:exec
,start
,stop
,publish
,delete
,edit
, etc) could be passed-t <tag name>
and automatically apply to all VMs with that tag.Tags could be managed with
alpine edit
or by editingconfig.yaml
directly, or with analpine tag <vm name> <tag>
to add a tag, andalpine tag -d <vm name> <tag>
to remove a tag if found.Tags could be made case-non-sensitive, and globally lower-cased, for implementation convenience.
Examples:
alpine publish -t fleet
: publish all VMs with tagfleet
alpine exec -t service "chronyc refresh && chronyc makestep && hwclock -w"
: update chrony NTP daemon and sync hardware clock on all VMs with tagservice
alpine list -t active
: display status information for VMs taggedactive