Skip to content

Docker module doesn't work in AmazonLinux2 #962

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Open
karthik-jaganathan opened this issue Nov 22, 2023 · 3 comments
Open

Docker module doesn't work in AmazonLinux2 #962

karthik-jaganathan opened this issue Nov 22, 2023 · 3 comments
Labels

Comments

@karthik-jaganathan
Copy link

Describe the Bug

The Docker module is not working in AmazonLinux2 ARM hosts. There is a validation in the init.pp , it checks for RHEL >= 7. However, AmazonLinux2 VERSION has value of 2 so the above conditional check fails and module execution is exiting

NAME="Amazon Linux"
VERSION="2"
ID="amzn"
ID_LIKE="centos rhel fedora"
VERSION_ID="2"

Expected Behavior

Docker module should support all RHEL/Debian flaours

Steps to Reproduce

Steps to reproduce the behavior:

  1. Refer here for the validation
    fail('This module only works on Debian, Red Hat or Windows based systems.')

Environment

  • Version [Docker version 20.10.25, build b82b9f3]
  • Platform [AmazonLinux2 ARM x86_64]

Additional Context

Add any other context about the problem here.

@rjd1
Copy link
Contributor

rjd1 commented Mar 15, 2024

Encountered the same issue recently and created a PR to address it. This change adds an exception to the RedHat 7 check for Amazon and another check below to fail if not Amazon Linux 2 or newer, effectively maintaining the same compatibility standard for that distribution.

@vikasperi
Copy link

Having the same issue.

amitkarsale pushed a commit to rjd1/puppetlabs-docker that referenced this issue Mar 7, 2025
amitkarsale added a commit that referenced this issue Mar 10, 2025
(GH-962) Allow Amazon Linux 2 and newer versions
@owenbeckles
Copy link

owenbeckles commented May 7, 2025

Having a similar issue with Amazon Linux 2023 while trying to install cd4pe on my test env - the puppetlabs-docker module is hard-coding the wrong url while trying to install the repo

It seems this is what's causing the issue

$package_ce_source_location = "https://download.docker.com/linux/rhel/${facts['os']['release']['major']}/${facts['os']['architecture']}/${docker_ce_channel}"

Image

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants