2021-04-28 01:35:28 +00:00
name : Upstream self-hosted
on :
push :
2022-10-04 12:20:23 +00:00
branches : [ master ]
2022-08-11 04:23:58 +00:00
paths : [ '**.c' , '**.h' , '.github/**' ]
2021-04-28 01:35:28 +00:00
jobs :
selfhosted :
if : github.repository == 'openssh/openssh-portable-selfhosted'
2022-12-13 09:59:54 +00:00
runs-on : 'libvirt'
2021-04-28 01:35:28 +00:00
env :
2022-12-13 09:55:37 +00:00
HOST : 'libvirt'
2022-11-26 22:28:20 +00:00
TARGET_HOST : ${{ matrix.target }}
2022-11-27 01:14:00 +00:00
TARGET_CONFIG : ${{ matrix.config }}
2021-04-28 01:35:28 +00:00
strategy :
fail-fast : false
matrix :
2022-11-26 22:28:20 +00:00
target : [ obsdsnap, obsdsnap-i386 ]
2022-11-27 01:14:00 +00:00
config : [ default, without-openssl, ubsan ]
2021-04-28 01:35:28 +00:00
steps :
- name : shutdown VM if running
run : vmshutdown
2022-11-08 00:33:25 +00:00
working-directory : ${{ runner.temp }}
2022-11-08 01:42:52 +00:00
- uses : actions/checkout@main
2021-04-28 01:35:28 +00:00
- name : startup VM
run : vmstartup
2022-11-27 01:19:37 +00:00
working-directory : ${{ runner.temp }}
2021-04-28 01:35:28 +00:00
- name : update source
run : vmrun "cd /usr/src && cvs up -dPA usr.bin/ssh regress/usr.bin/ssh"
2021-07-24 03:02:51 +00:00
- name : make clean
2022-12-18 10:36:25 +00:00
run : vmrun "cd /usr/src/usr.bin/ssh && make obj && make clean && cd /usr/src/regress/usr.bin/ssh && make obj && make clean && sudo chmod -R g-w /usr/src /usr/obj"
2021-04-28 01:35:28 +00:00
- name : make
2022-11-27 01:14:00 +00:00
run : vmrun "cd /usr/src/usr.bin/ssh && case ${{ matrix.config }} in without-openssl) make OPENSSL=no;; ubsan) make DEBUG='-fsanitize-minimal-runtime -fsanitize=undefined';; *) make; esac"
2021-04-28 01:35:28 +00:00
- name : make install
run : vmrun "cd /usr/src/usr.bin/ssh && sudo make install"
2022-05-06 04:39:34 +00:00
- name : make tests`
2022-11-27 01:14:00 +00:00
run : vmrun "cd /usr/src/regress/usr.bin/ssh && case ${{ matrix.config }} in without-openssl) make OPENSSL=no;; ubsan) make DEBUG='-fsanitize-minimal-runtime -fsanitize=undefined';; *) make; esac"
2022-05-06 04:39:34 +00:00
env :
SUDO : sudo
2021-12-10 00:57:30 +00:00
timeout-minutes : 300
2021-06-07 09:19:23 +00:00
- name : save logs
if : failure()
2022-11-07 22:21:10 +00:00
uses : actions/upload-artifact@main
2021-06-07 09:19:23 +00:00
with :
2022-11-27 01:14:00 +00:00
name : ${{ matrix.target }}-${{ matrix.config }}-logs
2021-06-07 09:19:23 +00:00
path : |
2022-12-18 10:13:42 +00:00
/usr/obj/regress/usr.bin/ssh/obj/*.log
2021-04-28 01:35:28 +00:00
- name : shutdown VM
if : always()
run : vmshutdown
2022-11-08 00:33:25 +00:00
working-directory : ${{ runner.temp }}