charmed-kubernetes / actions-operator

Apache License 2.0
7 stars 18 forks source link

Add optional input for microk8s group name #43

Closed stonepreston closed 2 years ago

stonepreston commented 2 years ago

Fixes issue 42.

When using strict microk8s, the group name is not micro8s (which was previously hardcoded) but is instead snap_microk8s. This PR adds an optional input to specify a group name. If unset, it defaults to "", and then the action picks a sensible value for the group name depending on if the microk8s is coming from a strict channel or not. This ensures workflows previously using the action will still work without any changes required, but provides some flexibility should the group name need to change in the future.

Additionally, if using strict juju (such as juju 3.0), the local/share/juju directory needs to exist ahead of bootstrap, as strictly confined juju cannot create this directory itself. This directory is now created before the bootstrap process begins to avoid issues.

Note that this PR is using the master branch of python lib juju, and will need to be updated when the new version is available from pypi. DO NOT MERGE UNTIL THAT HAPPENS

jnsgruk commented 2 years ago

I think now juju/python-libjuju#749 is merged, this should be good to go. I think a full release of python-libjuju is imminent, though @juanmanuel-tirado or @cderici will be able to confirm

juanmanuel-tirado commented 2 years ago

A new release will be released today or early next week to support Juju 3.0.0 and 2.9.36.