Add self-hosted runners for VMs of other platforms.
Github only hosts a limited number of platforms, and the runner code
is only supported on slightly wider range of platforms. To increase
our test coverage beyond that, we run the runner natively on a VM host,
where it runs a jobs that boot VMs of other platforms, waits for them
to come up then runs the build and test by ssh'ing into the guest.
This means that the minimum dependencies for the guests are quite low
(basically just sshd, a compiler and make).
The interface to the VM host is fairly simple (basically 3 scripts:
vmstartup, vmrun and vmshutdown), but those are specific to the VM host
so are not in the public repo. We also mount the working directory on the
host via sshfs, so things like artifact upload by the runner also work.
As part of this we are moving the per-test-target configs into a single
place (.github/configs) where there will be referenced by a single short
"config" key. I plan to make the github-hosted runners use this too.
The self-hosted runners are run off a private repo on github since that
prevents third parties from accessing them[0], and since runner quota is
limited on private repos, we avoid running the tests we run on the public
repo.
[0] https://docs.github.com/en/actions/hosting-your-own-runners/about-self-hosted-runners#self-hosted-runner-security-with-public-repositories
2021-01-15 04:11:43 +01:00
|
|
|
name: C/C++ CI self-hosted
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches: [ master, ci ]
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
selfhosted:
|
2021-02-17 08:27:36 +01:00
|
|
|
if: github.repository == 'openssh/openssh-portable-selfhosted'
|
2021-02-19 12:18:50 +01:00
|
|
|
runs-on: ${{ matrix.os }}
|
Add self-hosted runners for VMs of other platforms.
Github only hosts a limited number of platforms, and the runner code
is only supported on slightly wider range of platforms. To increase
our test coverage beyond that, we run the runner natively on a VM host,
where it runs a jobs that boot VMs of other platforms, waits for them
to come up then runs the build and test by ssh'ing into the guest.
This means that the minimum dependencies for the guests are quite low
(basically just sshd, a compiler and make).
The interface to the VM host is fairly simple (basically 3 scripts:
vmstartup, vmrun and vmshutdown), but those are specific to the VM host
so are not in the public repo. We also mount the working directory on the
host via sshfs, so things like artifact upload by the runner also work.
As part of this we are moving the per-test-target configs into a single
place (.github/configs) where there will be referenced by a single short
"config" key. I plan to make the github-hosted runners use this too.
The self-hosted runners are run off a private repo on github since that
prevents third parties from accessing them[0], and since runner quota is
limited on private repos, we avoid running the tests we run on the public
repo.
[0] https://docs.github.com/en/actions/hosting-your-own-runners/about-self-hosted-runners#self-hosted-runner-security-with-public-repositories
2021-01-15 04:11:43 +01:00
|
|
|
env:
|
2021-02-19 12:18:50 +01:00
|
|
|
TARGET_HOST: ${{ matrix.os }}
|
Add self-hosted runners for VMs of other platforms.
Github only hosts a limited number of platforms, and the runner code
is only supported on slightly wider range of platforms. To increase
our test coverage beyond that, we run the runner natively on a VM host,
where it runs a jobs that boot VMs of other platforms, waits for them
to come up then runs the build and test by ssh'ing into the guest.
This means that the minimum dependencies for the guests are quite low
(basically just sshd, a compiler and make).
The interface to the VM host is fairly simple (basically 3 scripts:
vmstartup, vmrun and vmshutdown), but those are specific to the VM host
so are not in the public repo. We also mount the working directory on the
host via sshfs, so things like artifact upload by the runner also work.
As part of this we are moving the per-test-target configs into a single
place (.github/configs) where there will be referenced by a single short
"config" key. I plan to make the github-hosted runners use this too.
The self-hosted runners are run off a private repo on github since that
prevents third parties from accessing them[0], and since runner quota is
limited on private repos, we avoid running the tests we run on the public
repo.
[0] https://docs.github.com/en/actions/hosting-your-own-runners/about-self-hosted-runners#self-hosted-runner-security-with-public-repositories
2021-01-15 04:11:43 +01:00
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
# We use a matrix in two parts: firstly all of the VMs are tested with the
|
2021-07-14 03:26:12 +02:00
|
|
|
# default config. "os" corresponds to a label associated with the worker.
|
Add self-hosted runners for VMs of other platforms.
Github only hosts a limited number of platforms, and the runner code
is only supported on slightly wider range of platforms. To increase
our test coverage beyond that, we run the runner natively on a VM host,
where it runs a jobs that boot VMs of other platforms, waits for them
to come up then runs the build and test by ssh'ing into the guest.
This means that the minimum dependencies for the guests are quite low
(basically just sshd, a compiler and make).
The interface to the VM host is fairly simple (basically 3 scripts:
vmstartup, vmrun and vmshutdown), but those are specific to the VM host
so are not in the public repo. We also mount the working directory on the
host via sshfs, so things like artifact upload by the runner also work.
As part of this we are moving the per-test-target configs into a single
place (.github/configs) where there will be referenced by a single short
"config" key. I plan to make the github-hosted runners use this too.
The self-hosted runners are run off a private repo on github since that
prevents third parties from accessing them[0], and since runner quota is
limited on private repos, we avoid running the tests we run on the public
repo.
[0] https://docs.github.com/en/actions/hosting-your-own-runners/about-self-hosted-runners#self-hosted-runner-security-with-public-repositories
2021-01-15 04:11:43 +01:00
|
|
|
matrix:
|
2021-04-16 10:14:25 +02:00
|
|
|
os:
|
2021-07-14 03:26:12 +02:00
|
|
|
- ARM64
|
2021-04-16 10:14:25 +02:00
|
|
|
- bbone
|
|
|
|
- dfly30
|
|
|
|
- dfly48
|
|
|
|
- dfly58
|
2021-06-02 03:17:54 +02:00
|
|
|
- dfly60
|
2021-04-16 10:14:25 +02:00
|
|
|
- fbsd6
|
2021-04-26 05:35:44 +02:00
|
|
|
- fbsd10
|
2021-04-16 10:14:25 +02:00
|
|
|
- fbsd12
|
|
|
|
- fbsd13
|
2021-05-27 13:13:38 +02:00
|
|
|
- minix3
|
2021-04-24 14:03:46 +02:00
|
|
|
# - nbsd2
|
2021-04-25 05:01:34 +02:00
|
|
|
- nbsd3
|
|
|
|
- nbsd4
|
2021-04-20 15:31:29 +02:00
|
|
|
- nbsd8
|
2021-04-25 05:01:34 +02:00
|
|
|
- nbsd9
|
2021-04-17 01:55:47 +02:00
|
|
|
- obsd51
|
2021-04-23 06:41:13 +02:00
|
|
|
- obsd67
|
2021-04-23 06:54:10 +02:00
|
|
|
- obsd68
|
2021-05-01 12:07:47 +02:00
|
|
|
- obsd69
|
2021-04-28 04:22:11 +02:00
|
|
|
- obsdsnap
|
2021-04-23 02:28:28 +02:00
|
|
|
- openindiana
|
2021-07-03 11:17:31 +02:00
|
|
|
# - rocky84
|
2021-04-16 10:14:25 +02:00
|
|
|
- sol10
|
|
|
|
- sol11
|
2021-04-20 17:08:04 +02:00
|
|
|
- win10
|
Add self-hosted runners for VMs of other platforms.
Github only hosts a limited number of platforms, and the runner code
is only supported on slightly wider range of platforms. To increase
our test coverage beyond that, we run the runner natively on a VM host,
where it runs a jobs that boot VMs of other platforms, waits for them
to come up then runs the build and test by ssh'ing into the guest.
This means that the minimum dependencies for the guests are quite low
(basically just sshd, a compiler and make).
The interface to the VM host is fairly simple (basically 3 scripts:
vmstartup, vmrun and vmshutdown), but those are specific to the VM host
so are not in the public repo. We also mount the working directory on the
host via sshfs, so things like artifact upload by the runner also work.
As part of this we are moving the per-test-target configs into a single
place (.github/configs) where there will be referenced by a single short
"config" key. I plan to make the github-hosted runners use this too.
The self-hosted runners are run off a private repo on github since that
prevents third parties from accessing them[0], and since runner quota is
limited on private repos, we avoid running the tests we run on the public
repo.
[0] https://docs.github.com/en/actions/hosting-your-own-runners/about-self-hosted-runners#self-hosted-runner-security-with-public-repositories
2021-01-15 04:11:43 +01:00
|
|
|
configs:
|
|
|
|
- default
|
|
|
|
# Then we include any extra configs we want to test for specific VMs.
|
|
|
|
include:
|
2021-07-14 03:26:50 +02:00
|
|
|
- { os: ARM64, configs: pam }
|
|
|
|
- { os: dfly30, configs: without-openssl}
|
|
|
|
- { os: dfly48, configs: pam }
|
|
|
|
- { os: dfly58, configs: pam }
|
|
|
|
- { os: dfly60, configs: pam }
|
|
|
|
- { os: fbsd6, configs: pam }
|
|
|
|
- { os: fbsd10, configs: pam }
|
|
|
|
- { os: fbsd12, configs: pam }
|
|
|
|
- { os: fbsd13, configs: pam }
|
|
|
|
- { os: nbsd8, configs: pam }
|
|
|
|
- { os: nbsd9, configs: pam }
|
|
|
|
- { os: openindiana, configs: pam }
|
|
|
|
# - { os: rocky84, configs: pam }
|
|
|
|
- { os: sol10, configs: pam }
|
|
|
|
- { os: sol11, configs: pam-krb5 }
|
|
|
|
- { os: sol11, configs: sol64 }
|
|
|
|
# - { os: sol11, configs: sol64-pam }
|
Add self-hosted runners for VMs of other platforms.
Github only hosts a limited number of platforms, and the runner code
is only supported on slightly wider range of platforms. To increase
our test coverage beyond that, we run the runner natively on a VM host,
where it runs a jobs that boot VMs of other platforms, waits for them
to come up then runs the build and test by ssh'ing into the guest.
This means that the minimum dependencies for the guests are quite low
(basically just sshd, a compiler and make).
The interface to the VM host is fairly simple (basically 3 scripts:
vmstartup, vmrun and vmshutdown), but those are specific to the VM host
so are not in the public repo. We also mount the working directory on the
host via sshfs, so things like artifact upload by the runner also work.
As part of this we are moving the per-test-target configs into a single
place (.github/configs) where there will be referenced by a single short
"config" key. I plan to make the github-hosted runners use this too.
The self-hosted runners are run off a private repo on github since that
prevents third parties from accessing them[0], and since runner quota is
limited on private repos, we avoid running the tests we run on the public
repo.
[0] https://docs.github.com/en/actions/hosting-your-own-runners/about-self-hosted-runners#self-hosted-runner-security-with-public-repositories
2021-01-15 04:11:43 +01:00
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
- name: autoreconf
|
|
|
|
run: autoreconf
|
|
|
|
- name: shutdown VM if running
|
|
|
|
run: vmshutdown
|
|
|
|
- name: startup VM
|
|
|
|
run: vmstartup
|
|
|
|
- name: configure
|
|
|
|
run: vmrun ./.github/configure.sh ${{ matrix.configs }}
|
|
|
|
- name: make
|
|
|
|
run: vmrun make
|
|
|
|
- name: make tests
|
|
|
|
run: vmrun ./.github/run_test.sh ${{ matrix.configs }}
|
2021-04-03 07:59:10 +02:00
|
|
|
- name: save logs
|
Add self-hosted runners for VMs of other platforms.
Github only hosts a limited number of platforms, and the runner code
is only supported on slightly wider range of platforms. To increase
our test coverage beyond that, we run the runner natively on a VM host,
where it runs a jobs that boot VMs of other platforms, waits for them
to come up then runs the build and test by ssh'ing into the guest.
This means that the minimum dependencies for the guests are quite low
(basically just sshd, a compiler and make).
The interface to the VM host is fairly simple (basically 3 scripts:
vmstartup, vmrun and vmshutdown), but those are specific to the VM host
so are not in the public repo. We also mount the working directory on the
host via sshfs, so things like artifact upload by the runner also work.
As part of this we are moving the per-test-target configs into a single
place (.github/configs) where there will be referenced by a single short
"config" key. I plan to make the github-hosted runners use this too.
The self-hosted runners are run off a private repo on github since that
prevents third parties from accessing them[0], and since runner quota is
limited on private repos, we avoid running the tests we run on the public
repo.
[0] https://docs.github.com/en/actions/hosting-your-own-runners/about-self-hosted-runners#self-hosted-runner-security-with-public-repositories
2021-01-15 04:11:43 +01:00
|
|
|
if: failure()
|
|
|
|
uses: actions/upload-artifact@v2
|
|
|
|
with:
|
2021-04-03 07:59:10 +02:00
|
|
|
name: ${{ matrix.os }}-${{ matrix.configs }}-logs
|
2021-02-20 03:06:25 +01:00
|
|
|
path: |
|
2021-04-03 07:59:10 +02:00
|
|
|
config.h
|
|
|
|
config.log
|
2021-02-20 03:06:25 +01:00
|
|
|
regress/*.log
|
|
|
|
regress/valgrind-out/
|
Add self-hosted runners for VMs of other platforms.
Github only hosts a limited number of platforms, and the runner code
is only supported on slightly wider range of platforms. To increase
our test coverage beyond that, we run the runner natively on a VM host,
where it runs a jobs that boot VMs of other platforms, waits for them
to come up then runs the build and test by ssh'ing into the guest.
This means that the minimum dependencies for the guests are quite low
(basically just sshd, a compiler and make).
The interface to the VM host is fairly simple (basically 3 scripts:
vmstartup, vmrun and vmshutdown), but those are specific to the VM host
so are not in the public repo. We also mount the working directory on the
host via sshfs, so things like artifact upload by the runner also work.
As part of this we are moving the per-test-target configs into a single
place (.github/configs) where there will be referenced by a single short
"config" key. I plan to make the github-hosted runners use this too.
The self-hosted runners are run off a private repo on github since that
prevents third parties from accessing them[0], and since runner quota is
limited on private repos, we avoid running the tests we run on the public
repo.
[0] https://docs.github.com/en/actions/hosting-your-own-runners/about-self-hosted-runners#self-hosted-runner-security-with-public-repositories
2021-01-15 04:11:43 +01:00
|
|
|
- name: shutdown VM
|
|
|
|
if: always()
|
|
|
|
run: vmshutdown
|