-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Co-authored-by: Hien To <[email protected]>
- Loading branch information
1 parent
6c85652
commit cf47200
Showing
6 changed files
with
157 additions
and
5 deletions.
There are no files selected for viewing
91 changes: 91 additions & 0 deletions
91
.github/runners/actions-runner-ubuntu-2004-arm64.dockerfile
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,91 @@ | ||
# Use NVIDIA CUDA 12.0.0 development image with Ubuntu 18.04 as the base | ||
FROM ubuntu:20.04 | ||
|
||
# Docker and Docker Compose arguments | ||
|
||
# Use 1001 and 121 for compatibility with GitHub-hosted runners | ||
ARG RUNNER_UID=1000 | ||
ARG DOCKER_GID=1001 | ||
|
||
ENV DEBIAN_FRONTEND=noninteractive | ||
|
||
# Install necessary packages | ||
RUN apt-get update -y \ | ||
&& apt-get install -y software-properties-common \ | ||
&& add-apt-repository -y ppa:git-core/ppa \ | ||
&& apt-get update -y \ | ||
&& apt-get install -y --no-install-recommends \ | ||
build-essential \ | ||
curl \ | ||
ca-certificates \ | ||
dnsutils \ | ||
ftp \ | ||
git \ | ||
uuid-dev \ | ||
iproute2 \ | ||
iputils-ping \ | ||
jq \ | ||
libunwind8 \ | ||
locales \ | ||
netcat \ | ||
openssh-client \ | ||
parallel \ | ||
python3-pip \ | ||
rsync \ | ||
shellcheck \ | ||
sudo \ | ||
telnet \ | ||
time \ | ||
tzdata \ | ||
unzip \ | ||
upx \ | ||
wget \ | ||
lsb-release \ | ||
openssl \ | ||
libssl-dev \ | ||
manpages-dev \ | ||
zip \ | ||
zstd \ | ||
pkg-config \ | ||
ccache \ | ||
gcc \ | ||
g++ \ | ||
&& ln -sf /usr/bin/python3 /usr/bin/python \ | ||
&& ln -sf /usr/bin/pip3 /usr/bin/pip \ | ||
&& rm -rf /var/lib/apt/lists/* | ||
|
||
# Add Kitware's APT repository for CMake | ||
RUN wget -O - https://apt.kitware.com/keys/kitware-archive-latest.asc 2>/dev/null | gpg --dearmor - | tee /etc/apt/trusted.gpg.d/kitware.gpg >/dev/null && \ | ||
apt-add-repository "deb https://apt.kitware.com/ubuntu/ $(lsb_release -cs) main" && \ | ||
apt-get update && \ | ||
apt-get install -y cmake | ||
|
||
# Download latest git-lfs version | ||
RUN curl -s https://packagecloud.io/install/repositories/github/git-lfs/script.deb.sh | bash && \ | ||
apt-get install -y --no-install-recommends git-lfs | ||
|
||
ARG RUNNER_VERSION=2.321.0 | ||
|
||
RUN adduser --disabled-password --gecos "" --uid $RUNNER_UID runner \ | ||
&& groupadd docker --gid $DOCKER_GID \ | ||
&& usermod -aG sudo runner \ | ||
&& usermod -aG docker runner \ | ||
&& echo "%sudo ALL=(ALL:ALL) NOPASSWD:ALL" > /etc/sudoers \ | ||
&& echo "Defaults env_keep += \"DEBIAN_FRONTEND\"" >> /etc/sudoers | ||
|
||
ENV HOME=/home/runner | ||
|
||
# cd into the user directory, download and unzip the github actions runner | ||
RUN cd /home/runner && mkdir actions-runner && cd actions-runner \ | ||
&& curl -O -L https://github.com/actions/runner/releases/download/v${RUNNER_VERSION}/actions-runner-linux-arm64-${RUNNER_VERSION}.tar.gz \ | ||
&& tar xzf ./actions-runner-linux-arm64-${RUNNER_VERSION}.tar.gz | ||
|
||
RUN chown -R runner:runner /home/runner && /home/runner/actions-runner/bin/installdependencies.sh | ||
|
||
ADD ./start.sh /home/runner/start.sh | ||
|
||
RUN chmod +x /home/runner/start.sh | ||
|
||
ENTRYPOINT ["/bin/bash", "/home/runner/start.sh"] | ||
|
||
USER runner |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters