Closed smacz42 closed 3 years ago
Hi,
Do you have a use case where you can't install Docker without the current set of apt packages?
IMO it's a really fine line with apt packages because wanting to add custom packages unrelated to installing Docker itself doesn't feel like something to optimize for in this role.
Do you have a use case where you can't install Docker without the current set of apt packages?
No. I can install docker just fine with the pkgs installed. And taking that point of view, I can have the necessary apt packages installed outside of that role before it is called.
Sounds good, yeah usually with roles I try to break them up to solve 1 problem. I wouldn't avoid creating more roles, even if they are pretty small.
In a similar way that
docker__default_pip_packages
hasdocker__pip_packages
that allows for additional packages to be installed via pip, there should be a corollary fordocker__package_dependencies
that allows for an addition to the list, without having to override that variable completely.For instance, if I have a pip package that I need to install that has a requirement on a package to be installed via apt (e.g.
python-systemd
relies onpkg-config
) I can install that apt package as an additional packages to the ones that are installed by default. This has the additional benefit of letting me delegate the "default" packages to be installed upstream to this role.