puppetlabs-docker icon indicating copy to clipboard operation
puppetlabs-docker copied to clipboard

Should also manage docker-ce-cli package with docker-ce

Open antaflos opened this issue 3 years ago • 0 comments

Describe the Bug

For Docker CE packages: when managing the Docker package (docker::manage_package => true) but not setting docker::package_source (i.e. packages are installed from APT or YUM repos available to the system) then the docker-ce-cli package remains unmanaged by Puppet.

This leads to problems when updating the Docker CE packages (i.e. bumping docker::version) down the line, because the docker-ce-cli package remains at the version at which it was originally installed. Thus docker-ce and docker-ce-cli versions drift apart.

This could also be interpreted as a bug in the Docker packages since docker-ce doesn't enforce docker-ce-cli to be installed in the same version (it just depends on any version of docker-ce-cli). Maybe this is intentional?

Expected Behavior

When managing the Docker CE package docker-ce without setting docker::package_source then the CLI package docker-ce-cli should also be managed and set to the same version as the docker-ce package.

Steps to Reproduce

  1. Enable Docker APT repo
  2. Install Docker CE by means of puppetlabs-docker
  3. Bump docker::version
  4. Observe that docker-ce-cli remains at the originally installed version while docker-ce is bumped to the version specified in docker::version

Environment

  • Docker 20.10.x
  • puppetlabs-docker 5.0.0
  • Ubuntu 20.04, probably also RHEL and others

Additional Context

PRs #740 and #827 deal with this issue but only when docker::package_source is used. The case when packages are installed from system-wide enabled APT (or YUM) repos is left out.

antaflos avatar Oct 17 '22 15:10 antaflos