Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Fix azure_docker_rancher terraform to use older Docker version and newer Rancher version #226

Merged
merged 1 commit into from
Jan 30, 2024

Conversation

aiyengar2
Copy link

@aiyengar2 aiyengar2 commented Jan 29, 2024

Currently, it seems like the install step for downloading Docker via https://releases.rancher.com/install-docker/${docker_version}.sh does not seem to work for 24.0.

echo "Installing Docker..."
curl https://releases.rancher.com/install-docker/${docker_version}.sh | sh;

More investigation is required before upgrading, but for now we can revert back to using a previous working Docker version.

This PR also bumps to use the 2.8.1 release of Rancher by default.


The error encountered is as follows:

root@<REDACTED>:~# curl https://releases.rancher.com/install-docker/24.0.sh | sh
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 24599  100 24599    0     0   212k      0 --:--:-- --:--:-- --:--:--  212k
# Executing docker install script, commit: e5543d473431b782227f8908005543bb4389b8de
Warning: the "docker" command appears to already exist on this system.

If you already have Docker installed, this script can cause trouble, which is
why we're displaying this warning and provide the opportunity to cancel the
installation.

If you installed the current Docker package using this script and are using it
again to update Docker, you can safely ignore this message.

You may press Ctrl+C now to abort this script.
+ sleep 20
+ sh -c apt-get update -qq >/dev/null
+ sh -c DEBIAN_FRONTEND=noninteractive apt-get install -y -qq apt-transport-https ca-certificates curl >/dev/null
+ sh -c install -m 0755 -d /etc/apt/keyrings
+ sh -c curl -fsSL "https://download.docker.com/linux/ubuntu/gpg" | gpg --dearmor --yes -o /etc/apt/keyrings/docker.gpg
+ sh -c chmod a+r /etc/apt/keyrings/docker.gpg
+ sh -c echo "deb [arch=amd64 signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/ubuntu bionic stable" > /etc/apt/sources.list.d/docker.list
+ sh -c apt-get update -qq >/dev/null
INFO: Searching repository for VERSION '24.0.7'
INFO: apt-cache madison docker-ce | grep '24.0.7' | head -1 | awk '{$1=$1};1' | cut -d' ' -f 3

ERROR: '24.0.7' not found amongst apt-cache madison results

@aiyengar2 aiyengar2 changed the title Fix azure_docker_rancher terraform to use older Docker version Fix azure_docker_rancher terraform to use older Docker version and newer Rancher version Jan 29, 2024
@aiyengar2 aiyengar2 marked this pull request as ready for review January 29, 2024 21:58
@aiyengar2
Copy link
Author

Update: This is probably because we use Ubuntu 18.04 as our default OS:

default_linux_image = "ubuntu-1804"

Docker Engine docs now indicate that they only seem to support 22.04 LTS and above.

Created issue in #227

@aiyengar2 aiyengar2 merged commit 7a665c1 into rancher:main Jan 30, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants