From 9324bee6e531356c27551ace3fbbd80858fd8faa Mon Sep 17 00:00:00 2001 From: Charlie Briggs Date: Thu, 11 Jan 2024 11:59:24 +0000 Subject: [PATCH 1/2] Add arm64 support --- .circleci/config.yml | 2 +- Dockerfile.template | 3 ++- manifest | 2 ++ shared | 2 +- 4 files changed, 6 insertions(+), 3 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 39e87c7..9d9f048 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -1,7 +1,7 @@ version: 2.1 orbs: - cimg: circleci/cimg@0.3.0 + cimg: circleci/cimg@0.3.3 workflows: main-wf: diff --git a/Dockerfile.template b/Dockerfile.template index 5ca3230..45c7201 100644 --- a/Dockerfile.template +++ b/Dockerfile.template @@ -27,6 +27,7 @@ RUN mkdir -p $HOME/bin && \ # Install tooling ENV BABASHKA_VERSION=0.10.163 -RUN curl -sSL "https://github.com/babashka/babashka/releases/download/v${BABASHKA_VERSION}/babashka-${BABASHKA_VERSION}-linux-amd64-static.tar.gz" \ +RUN [[ $(uname -m) == "x86_64" ]] && ARCH="amd64" || ARCH="aarch64" && \ + curl -sSL "https://github.com/babashka/babashka/releases/download/v${BABASHKA_VERSION}/babashka-${BABASHKA_VERSION}-linux-${ARCH}-static.tar.gz" \ | sudo tar -xz -C /usr/local/bin/ && \ bb --version diff --git a/manifest b/manifest index 2a083bb..85dfb97 100644 --- a/manifest +++ b/manifest @@ -7,3 +7,5 @@ variants=(node browsers) parentTags=(8.0 11.0 17.0) defaultParentTag=17.0 parentSlug=openjdk + +arm64=1 diff --git a/shared b/shared index cdab031..59ebf05 160000 --- a/shared +++ b/shared @@ -1 +1 @@ -Subproject commit cdab031cf829da3be5f6d55bd9881f0d0e6da7ca +Subproject commit 59ebf05450832397e3c6b5eaf1dc12671d7ffd72 From 0c7e0d1a3c9bd41a42af939cafe9c2cc9b369b71 Mon Sep 17 00:00:00 2001 From: Charlie Briggs Date: Thu, 11 Jan 2024 12:09:28 +0000 Subject: [PATCH 2/2] Update images for arm --- 1.10/11.0/Dockerfile | 14 ++++++++------ 1.10/11.0/browsers/Dockerfile | 20 ++++++++++---------- 1.10/11.0/node/Dockerfile | 5 +++-- 1.10/17.0/Dockerfile | 14 ++++++++------ 1.10/17.0/browsers/Dockerfile | 20 ++++++++++---------- 1.10/17.0/node/Dockerfile | 5 +++-- 1.10/8.0/Dockerfile | 14 ++++++++------ 1.10/8.0/browsers/Dockerfile | 20 ++++++++++---------- 1.10/8.0/node/Dockerfile | 5 +++-- 1.11/11.0/Dockerfile | 7 ++++--- 1.11/11.0/node/Dockerfile | 5 +++-- 1.11/17.0/Dockerfile | 7 ++++--- 1.11/17.0/node/Dockerfile | 5 +++-- 1.11/8.0/Dockerfile | 7 ++++--- 1.11/8.0/node/Dockerfile | 5 +++-- build-images.sh | 21 ++++++++++++--------- push-images.sh | 31 +------------------------------ 17 files changed, 97 insertions(+), 108 deletions(-) diff --git a/1.10/11.0/Dockerfile b/1.10/11.0/Dockerfile index 52c1418..7126fae 100644 --- a/1.10/11.0/Dockerfile +++ b/1.10/11.0/Dockerfile @@ -2,19 +2,20 @@ FROM cimg/openjdk:11.0 -LABEL maintainer="Community & Partner Engineering Team " +LABEL maintainer="CircleCI Execution Team " -ENV CLOJURE_VERSION=1.10.3 +ENV CLOJURE_VERSION=1.10.3 \ + PATH=$JAVA_HOME/bin:$PATH # Setup the primary install method for Clojure, using CLJ. It unfortunately # requires the Clojure version as well as the build number (?), thus a # parameter (param1) is used. -RUN curl -sSL -o clojure-installer.sh "https://download.clojure.org/install/linux-install-1.10.3.1069.sh" && \ +RUN curl -sSL -o clojure-installer.sh "https://download.clojure.org/install/linux-install-1.10.3.1058.sh" && \ chmod +x clojure-installer.sh && \ sudo ./clojure-installer.sh && \ rm clojure-installer.sh -ENV LEIN_VERSION=2.9.10 +ENV LEIN_VERSION=2.10.0 RUN mkdir -p $HOME/bin && \ # the above line can go in the next base image update curl -sSL -o $HOME/bin/lein "https://raw.githubusercontent.com/technomancy/leiningen/${LEIN_VERSION}/bin/lein" && \ @@ -25,7 +26,8 @@ RUN mkdir -p $HOME/bin && \ rm -r project.clj target/ # Install tooling -ENV BABASHKA_VERSION=0.9.161 -RUN curl -sSL "https://github.com/babashka/babashka/releases/download/v0.7.4/babashka-0.7.4-linux-amd64-static.tar.gz" \ +ENV BABASHKA_VERSION=0.10.163 +RUN [[ $(uname -m) == "x86_64" ]] && ARCH="amd64" || ARCH="aarch64" && \ + curl -sSL "https://github.com/babashka/babashka/releases/download/v${BABASHKA_VERSION}/babashka-${BABASHKA_VERSION}-linux-${ARCH}-static.tar.gz" \ | sudo tar -xz -C /usr/local/bin/ && \ bb --version diff --git a/1.10/11.0/browsers/Dockerfile b/1.10/11.0/browsers/Dockerfile index 9c42dd5..cb2b6ab 100644 --- a/1.10/11.0/browsers/Dockerfile +++ b/1.10/11.0/browsers/Dockerfile @@ -11,6 +11,9 @@ RUN curl -sSL -o selenium-server-standalone-${SELENIUM_VER}.jar "https://seleniu rm selenium-server-standalone-${SELENIUM_VER}.jar RUN sudo apt-get update && \ + sudo apt-get install --yes --no-install-recommends \ + xvfb \ + && \ # Install Java only if it's not already available # Java is installed for Selenium @@ -32,25 +35,22 @@ RUN printf '#!/bin/sh\nXvfb :99 -screen 0 1280x1024x24 &\nexec "$@"\n' | sudo te sudo chmod +x /docker-entrypoint.sh # Install a single version of Firefox. This isn't intended to be a regularly -# updated thing. Instead, if this version of Firefox isn't want the end user +# updated thing. Instead, if this version of Firefox isn't what the end user # wants they should install a different version via the Browser Tools Orb. # # Canonical made a major technology change in how Firefox is installed from # Ubuntu 21.10 and up. The general CI space doesn't seem to be ready for a snap -# based Firefox right now so we are installing the original deb based version -# from Ubuntu Focal, even if the current Ubuntu version is newer. -RUN echo 'deb http://us.archive.ubuntu.com/ubuntu/ focal-updates main' | sudo tee /etc/apt/sources.list.d/firefox.list && \ - echo 'Package: firefox' | sudo tee -a /etc/apt/preferences.d/firefox.pref && \ - echo 'Pin: release n=focal' | sudo tee -a /etc/apt/preferences.d/firefox.pref && \ - echo 'Pin-Priority: 500' | sudo tee -a /etc/apt/preferences.d/firefox.pref && \ - - sudo apt-get update && \ +# based Firefox right now so we are installing it from the Mozilla PPA. +RUN echo 'Package: *' | sudo tee -a /etc/apt/preferences.d/firefox.pref && \ + echo 'Pin: release o=LP-PPA-mozillateam' | sudo tee -a /etc/apt/preferences.d/firefox.pref && \ + echo 'Pin-Priority: 1001' | sudo tee -a /etc/apt/preferences.d/firefox.pref && \ + sudo add-apt-repository --yes ppa:mozillateam/ppa && \ sudo apt-get install --no-install-recommends --yes firefox && \ sudo rm -rf /var/lib/apt/lists/* && \ firefox --version # Install a single version of Google Chrome Stable. This isn't intended to be a -# regularly updated thing. Instead, if this version of Chrome isn't want the +# regularly updated thing. Instead, if this version of Chrome isn't what the # end user wants they should install a different version via the Browser Tools # Orb. RUN wget -q -O - "https://dl.google.com/linux/linux_signing_key.pub" | sudo apt-key add - && \ diff --git a/1.10/11.0/node/Dockerfile b/1.10/11.0/node/Dockerfile index 758babb..e9489e6 100644 --- a/1.10/11.0/node/Dockerfile +++ b/1.10/11.0/node/Dockerfile @@ -7,12 +7,13 @@ LABEL maintainer="Community & Partner Engineering Team