From 792ea64d4dd56ac2616b21a1587a3cafca0188f1 Mon Sep 17 00:00:00 2001 From: Jason Yuen Date: Sat, 21 Dec 2024 05:21:51 -0500 Subject: [PATCH] Fix errors in tier2 (#80) --- tier2/Dockerfile | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/tier2/Dockerfile b/tier2/Dockerfile index d6399d1a..fc56b525 100644 --- a/tier2/Dockerfile +++ b/tier2/Dockerfile @@ -6,7 +6,7 @@ RUN apt-get update && \ $([ "$(arch)" = x86_64 ] && echo libc6-dev-i386) \ openjdk-22-jdk-headless clang llvm ghc golang racket ruby scala nasm chicken-bin && \ ( export OPAMYES=1 OPAMJOBS=$(($(nproc) + 2)); \ - apt-get install -y --no-install-recommends make m4 patch unzip libgmp-dev && \ + apt-get install -y --no-install-recommends make m4 patch unzip libgmp-dev pkg-config && \ bash -c 'echo | sh <(curl -sL https://raw.githubusercontent.com/ocaml/opam/master/shell/install.sh) --no-backup' && \ runuser -u judge -- opam init --shell-setup --disable-sandboxing --bare && \ runuser -u judge -- opam switch create dmoj --packages=ocaml.5.0.0,ocaml-option-flambda && \ @@ -14,11 +14,11 @@ RUN apt-get update && \ runuser -u judge -- opam clean && rm -rf ~judge/.opam/repo \ ) && \ if [ "$(arch)" = x86_64 ]; then PYPY_ARCH=linux64; else PYPY_ARCH="$(arch)"; fi && \ - mkdir /opt/pypy2 && curl -L "$(curl https://www.pypy.org/download.html | grep "/pypy2.*$PYPY_ARCH" | head -n1 | cut -d'"' -f4)" | \ + mkdir /opt/pypy2 && curl -L "$(curl https://pypy.org/download.html | grep "/pypy2.*$PYPY_ARCH" | head -n1 | cut -d'"' -f4)" | \ tar xj -C /opt/pypy2 --strip-components=1 && /opt/pypy2/bin/pypy -mcompileall && \ chmod a+rx /opt/pypy2/lib /opt/pypy2/lib/*.so* && \ rm -f /opt/pypy2/bin/python* && \ - mkdir /opt/pypy3 && curl -L "$(curl https://www.pypy.org/download.html | grep "/pypy3.*$PYPY_ARCH" | head -n1 | cut -d'"' -f4)" | \ + mkdir /opt/pypy3 && curl -L "$(curl https://pypy.org/download.html | grep "/pypy3.*$PYPY_ARCH" | head -n1 | cut -d'"' -f4)" | \ tar xj -C /opt/pypy3 --strip-components=1 && /opt/pypy3/bin/pypy -mcompileall && \ rm -f /opt/pypy3/bin/python* && \ runuser judge -c 'curl https://sh.rustup.rs -sSf | sh -s -- -y' && \ @@ -35,11 +35,12 @@ RUN apt-get update && \ rm -rf rust && \ if [ "$(arch)" = x86_64 ]; then curl -fsS https://dlang.org/install.sh | bash -s dmd --path /opt/dlang \ && mv /opt/dlang/dmd-*/* /opt/dlang && rmdir /opt/dlang/dmd-*; fi && \ - apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF && \ - echo "deb https://download.mono-project.com/repo/debian stable-buster main" > \ + gpg --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF && \ + gpg --export --armor 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF > /usr/share/keyrings/mono-official-archive-keyring.asc && \ + echo "deb [signed-by=/usr/share/keyrings/mono-official-archive-keyring.asc] https://download.mono-project.com/repo/debian stable-buster main" > \ /etc/apt/sources.list.d/mono-official-stable.list && \ - curl https://dmoj.ca/dmoj-apt.key | apt-key add - && \ - echo 'deb https://apt.dmoj.ca/ bullseye main' > /etc/apt/sources.list.d/dmoj.list && \ + curl https://dmoj.ca/dmoj-apt.key -o /usr/share/keyrings/dmoj-keyring.asc && \ + echo 'deb [signed-by=/usr/share/keyrings/dmoj-keyring.asc] https://apt.dmoj.ca/ bullseye main' > /etc/apt/sources.list.d/dmoj.list && \ (echo 'Package: *'; echo 'Pin: origin download.mono-project.com'; echo 'Pin-Priority: 990') > /etc/apt/preferences.d/mono && \ apt-get update && \ dpkg-divert --package mono-roslyn --divert /usr/bin/chicken-csc --rename /usr/bin/csc && \