OctopusDeploy / WorkerTools

| Public | Officially sanctioned worker images for Octopus Deploy
0 stars 25 forks source link

Ubuntu 22.04: Az CLI Points to Wrong Repository #72

Open johnbailey-transactcampus opened 1 year ago

johnbailey-transactcampus commented 1 year ago

Problem: When using the Ubuntu 22.04 image, and attempting to upgrade azure-cli, there will be an error about dependencies not being able to be installed: azure-cli : Depends: libffi6 (>= 3.0.10~rc8) but it is not installable

Root-Cause: The current repository that Az CLI is pulled from points to bionic and not jammy.

Proposed Solution: In order to resolve this, the base image should be changed to point to correct repository:

echo "deb [arch=amd64] https://packages.microsoft.com/repos/azure-cli/ jammy main" | tee /etc/apt/sources.list.d/azure-cli.list

Reason for Not Creating a PR: It looks like other dependencies (e.g.: openjdk-11) are no longer available, so other packages (overall) will/may need upgrading to implement this fix.

> [10/29] RUN apt-get install -y openjdk-11-jdk-headless=11.0.19+7~us1-0ubuntu1~22.04.1: 0.578 Reading package lists... 1.063 Building dependency tree... 1.163 Reading state information... 1.166 Package openjdk-11-jdk-headless is not available, but is referred to by another package. 1.166 This may mean that the package is missing, has been obsoleted, or 1.166 is only available from another source 1.166 However the following packages replace it: 1.166 openjdk-19-jre-headless openjdk-18-jre-headless openjdk-17-jre-headless 1.166 openjdk-11-jre-headless 1.166 1.169 E: Version '11.0.19+7~us1-0ubuntu1~22.04.1' for 'openjdk-11-jdk-headless' was not found