Solved Running Cloudron CLI commands on apps with tags?
d19dotca last edited by girish
I just had an idea and am not sure if this is possible (my current testing / review of the docs indicates this may not be possible but figured I'd double check)... I'd like to run one command ideally that creates backups for all app instances with a certain tag.
For example, I'd look to add the "WooCommerce" tag in Cloudron to apps using the WooCommerce plugin in WordPress, and before updating them all I'd like to initiate a backup in one quick command instead of manually generating them all. So something like
cloudron backup create --tag woocommerce, but it doesn't seem this is possible yet.
Right now any major plugin updates I always manually create backups, but it'd be nice to have things sorted out with a command to do them all at once if possible.
@d19dotca this is possible to add only on the cli side, so no Cloudron changes as such would be required.
The only thing I am a bit worried about here, is that currently all commands are working towards a single app instance, while with such a feature, multiple apps might be affected. Maybe instead we can think of better chainability of the cli tool. For example if there would be a
cloudron list --tag woocommercewhich produces a
xargsconsumable app id list to pipe into further cli commands, then this could open up a lot more use-cases.
d19dotca last edited by
@nebulon For sure. If there's some way to script it / automate it in a way using a list argument first, that works for me.
@d19dotca this is now implemented at https://git.cloudron.io/cloudron/cloudron-cli/-/commit/e321442cc2251f46b0ee2564138224015339b12d and will thus be part of next cli release.