Skip to content

Commit 00238f5

Browse files
committed
CI: add actuated-arm64
See <https://actuated.dev/blog/arm-ci-cncf-ampere>. Thanks to Alex Ellis, Ampere Computing, and Equinix. Host information: * CPU: aarch64 (ARMv8) * Kernel: 5.10.201 * Lacks ~CONFIG_CHECKPOINT_RESTORE~, CONFIG_BLK_CGROUP_IOCOST, etc. * Cgroup: v2 * OS: Ubuntu 22.04 * Lacks newuidmap, newgidmap, etc. (still apt-gettable) * sshd is not running vmmeter is added from: https://gist.github.com/alexellis/1f33e581c75e11e161fe613c46180771#file-metering-gha-md Signed-off-by: Akihiro Suda <[email protected]>
1 parent 758b2e2 commit 00238f5

File tree

2 files changed

+73
-7
lines changed

2 files changed

+73
-7
lines changed

.github/workflows/test.yml

Lines changed: 72 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ jobs:
2323
strategy:
2424
fail-fast: false
2525
matrix:
26-
os: [ubuntu-20.04, ubuntu-22.04]
26+
os: [ubuntu-20.04, ubuntu-22.04, actuated-arm64-6cpu-8gb]
2727
go-version: [1.20.x, 1.21.x]
2828
rootless: ["rootless", ""]
2929
race: ["-race", ""]
@@ -50,15 +50,81 @@ jobs:
5050
rootless: rootless
5151
- dmz: runc_nodmz
5252
race: -race
53+
- go-version: 1.20.x
54+
os: actuated-arm64-6cpu-8gb
55+
- race: "-race"
56+
os: actuated-arm64-6cpu-8gb
57+
- criu: criu-dev
58+
os: actuated-arm64-6cpu-8gb
59+
- dmz: runc_nodmz
60+
os: actuated-arm64-6cpu-8gb
61+
5362
runs-on: ${{ matrix.os }}
5463

5564
steps:
65+
# https://gist.github.com/alexellis/1f33e581c75e11e161fe613c46180771#file-metering-gha-md
66+
# vmmeter start
67+
- name: Prepare arkade
68+
uses: alexellis/arkade-get@master
69+
if: matrix.os == 'actuated-arm64-6cpu-8gb'
70+
with:
71+
crane: latest
72+
print-summary: false
73+
74+
- name: Install vmmeter
75+
if: matrix.os == 'actuated-arm64-6cpu-8gb'
76+
run: |
77+
crane export --platform linux/arm64 ghcr.io/openfaasltd/vmmeter:latest | sudo tar -xvf - -C /usr/local/bin
78+
79+
- name: Run vmmeter
80+
uses: self-actuated/vmmeter-action@master
81+
if: matrix.os == 'actuated-arm64-6cpu-8gb'
82+
# vmmeter end
5683

5784
- name: checkout
5885
uses: actions/checkout@v4
5986

87+
- name: Show host info
88+
run: |
89+
set -x
90+
# Sync `set -x` outputs with command ouputs
91+
exec 2>&1
92+
# Version
93+
uname -a
94+
cat /etc/os-release
95+
# Hardware
96+
cat /proc/cpuinfo
97+
free -mt
98+
# cgroup
99+
ls -F /sys/fs/cgroup
100+
cat /proc/self/cgroup
101+
if [ -e /sys/fs/cgroup/cgroup.controllers ]; then
102+
cat /sys/fs/cgroup/cgroup.controllers
103+
cat /sys/fs/cgroup/cgroup.subtree_control
104+
ls -F /sys/fs/cgroup$(grep -oP '0::\K.*' /proc/self/cgroup)
105+
fi
106+
# kernel config
107+
script/check-config.sh
108+
109+
- name: start sshd (used for testing rootless with systemd user session)
110+
if: ${{ matrix.os == 'actuated-arm64-6cpu-8gb' && matrix.rootless == 'rootless' }}
111+
run: |
112+
# Generate new keys to fix "sshd: no hostkeys available -- exiting."
113+
sudo ssh-keygen -A
114+
if ! sudo systemctl start ssh.service; then
115+
sudo journalctl -xeu ssh.service
116+
exit 1
117+
fi
118+
ps auxw | grep sshd
119+
60120
- name: install deps
61-
if: matrix.criu == ''
121+
run: |
122+
sudo apt update
123+
sudo apt -y install libseccomp-dev sshfs uidmap
124+
125+
- name: install CRIU
126+
# TODO: enable CRIU for actuated: https://github.com/opencontainers/runc/pull/4142#issuecomment-1945408382
127+
if: ${{ matrix.os != 'actuated-arm64-6cpu-8gb' && matrix.criu == '' }}
62128
env:
63129
PREFIX: https://download.opensuse.org/repositories/devel:/tools:/criu/xUbuntu
64130
run: |
@@ -67,13 +133,12 @@ jobs:
67133
curl -fSsLl $REPO/Release.key | gpg --dearmor | sudo tee /etc/apt/trusted.gpg.d/devel_tools_criu.gpg > /dev/null
68134
echo "deb $REPO/ /" | sudo tee /etc/apt/sources.list.d/criu.list
69135
sudo apt update
70-
sudo apt -y install libseccomp-dev criu sshfs
136+
sudo apt -y install criu
71137
72-
- name: install deps (criu ${{ matrix.criu }})
73-
if: matrix.criu != ''
138+
- name: install CRIU (criu ${{ matrix.criu }})
139+
if: ${{ matrix.os != 'actuated-arm64-6cpu-8gb' && matrix.criu != '' }}
74140
run: |
75-
sudo apt -q update
76-
sudo apt -qy install libseccomp-dev sshfs \
141+
sudo apt -qy install \
77142
libcap-dev libnet1-dev libnl-3-dev \
78143
libprotobuf-c-dev libprotobuf-dev protobuf-c-compiler protobuf-compiler
79144
git clone https://github.com/checkpoint-restore/criu.git ~/criu

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
[![gha/validate](https://github.com/opencontainers/runc/workflows/validate/badge.svg)](https://github.com/opencontainers/runc/actions?query=workflow%3Avalidate)
77
[![gha/ci](https://github.com/opencontainers/runc/workflows/ci/badge.svg)](https://github.com/opencontainers/runc/actions?query=workflow%3Aci)
88
[![CirrusCI](https://api.cirrus-ci.com/github/opencontainers/runc.svg)](https://cirrus-ci.com/github/opencontainers/runc)
9+
<a href="https://actuated.dev"><img alt="Arm CI sponsored by Actuated" src="https://docs.actuated.dev/images/actuated-badge.png" width="120px"></img></a>
910

1011
## Introduction
1112

0 commit comments

Comments
 (0)