-
Notifications
You must be signed in to change notification settings - Fork 45
/
spread.yaml
59 lines (54 loc) · 1.64 KB
/
spread.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
project: chisel
path: /chisel
environment:
OS: ubuntu
PRO_TOKEN: $(HOST:echo $PRO_TOKEN)
backends:
# Cannot use LXD backend due to https://github.com/snapcore/spread/issues/154
# lxd:
# systems:
# - ubuntu-bionic
# - ubuntu-focal
# - ubuntu-jammy
# GitHub actions (runners) don't support nested virtualization (https://github.com/community/community/discussions/8305)
# qemu:
# systems:
# - ubuntu-22.04:
# username: ubuntu
# password: ubuntu
# - ubuntu-22.10:
# username: ubuntu
# password: ubuntu
adhoc:
allocate: |
echo "Allocating $SPREAD_SYSTEM..."
image=$(echo $SPREAD_SYSTEM | tr '-' ':')
docker pull $image
docker run -e usr=$SPREAD_SYSTEM_USERNAME -e pass=$SPREAD_SYSTEM_PASSWORD --name $SPREAD_SYSTEM -d $image sh -c '
set -x
apt update
apt install -y openssh-server sudo zstd jq
mkdir /run/sshd
useradd -rm -d /home/ubuntu -s /bin/bash -g root -G sudo -u 1000 ubuntu
echo "$usr:$pass" | chpasswd
echo "$usr ALL=(ALL) NOPASSWD: ALL" >> /etc/sudoers
/usr/sbin/sshd -D
'
ADDRESS `docker inspect $SPREAD_SYSTEM --format '{{.NetworkSettings.Networks.bridge.IPAddress}}'`
discard:
docker rm -f $SPREAD_SYSTEM
systems:
- ubuntu-24.04:
username: ubuntu
password: ubuntu
prepare: |
apt install -y golang git
go build -buildvcs=false ./cmd/chisel/
mv chisel /usr/local/bin
suites:
tests/:
summary: Tests common scenarios
environment:
RELEASE/jammy: 22.04
RELEASE/focal: 20.04
RELEASE/noble: 24.04