The comfort level of multipass launch charm-dev
is quite high, but it has some problems:
- Different people want different things in their dev-env.
- Cannot reuse: the setup script needs to be duplicated to lxd profile, github action, concierge, …
- Multipass blueprints are being deprecated.
One way to address all the issues above is by using a justfile (I prefer just
over make
for this purpose).
They way you’d use it in a fresh multipass vm could be:
# Launch and shell into a vm
multipass launch noble --name charm-dev --memory 16G --cpus 8 --disk 100G
multipass shell charm-dev
# Now run these from within the vm
# 1. Obtain deps
sudo snap install --classic just
curl https://raw.githubusercontent.com/sed-i/reusable-justfiles/refs/heads/main/charm-dev/ubuntu-24.04.just
# 2. Set up dev-env
sudo just -f charm-dev_ubuntu-24.04.just charm-dev
Under the hood, the charm-dev
recipe depends on several other recipes:
charm-dev: update init utils microk8s juju starcraft default-models && _banner
One thing I am very curious to find out is, to what extent could a repo of reusable justfiles be a replacement for github actions.