|
1 | 1 | # NOTE Github Actions execution environments lack a terminal, needed for |
2 | | -# some integration tests. Two ways to get a terminal are used below: |
3 | | -# |
4 | | -# 1. script utility -- for "local" integration tests; |
5 | | -# 2. ssh -tt -- for Vagrant VMs (script is buggy on CentOS 7). |
| 2 | +# some integration tests. So we use `script` command to fake a terminal. |
6 | 3 |
|
7 | 4 | name: ci |
8 | 5 | on: |
|
73 | 70 | if: matrix.rootless != 'rootless' |
74 | 71 | run: sudo -E PATH="$PATH" script -e -c 'make RUNC_USE_SYSTEMD=yes local${{ matrix.rootless }}integration' |
75 | 72 |
|
76 | | - |
77 | | - # cgroup v2 unified hierarchy + very recent kernel (openat2) |
78 | | - fedora: |
79 | | - # nested virtualization is only available on macOS hosts |
80 | | - runs-on: macos-10.15 |
81 | | - timeout-minutes: 30 |
82 | | - # only run it if others have passed |
83 | | - needs: [test] |
84 | | - steps: |
85 | | - - uses: actions/checkout@v2 |
86 | | - |
87 | | - - name: "Cache ~/.vagrant.d/boxes, using hash of Vagrantfile.fedora34" |
88 | | - uses: actions/cache@v2 |
89 | | - with: |
90 | | - path: ~/.vagrant.d/boxes |
91 | | - key: vagrant-${{ hashFiles('Vagrantfile.fedora34') }} |
92 | | - |
93 | | - - name: prepare vagrant |
94 | | - run: | |
95 | | - ln -sf Vagrantfile.fedora34 Vagrantfile |
96 | | - # Retry if it fails (download.fedoraproject.org returns 404 sometimes) |
97 | | - vagrant up || vagrant up |
98 | | - vagrant ssh-config >> ~/.ssh/config |
99 | | -
|
100 | | - - name: system info |
101 | | - run: ssh default 'sh -exc "uname -a && systemctl --version && df -T"' |
102 | | - |
103 | | - - name: unit tests |
104 | | - run: ssh default 'cd /vagrant && sudo make localunittest' |
105 | | - |
106 | | - - name: cgroupv2 with systemd |
107 | | - run: ssh -tt default "sudo make -C /vagrant localintegration RUNC_USE_SYSTEMD=yes" |
108 | | - |
109 | | - - name: cgroupv2 with fs2 |
110 | | - run: ssh -tt default "sudo make -C /vagrant localintegration" |
111 | | - |
112 | | - - name: cgroupv2 with systemd (rootless) |
113 | | - run: ssh -tt default "sudo make -C /vagrant localrootlessintegration RUNC_USE_SYSTEMD=yes" |
114 | | - |
115 | | - - name: cgroupv2 with fs2 (rootless) |
116 | | - run: ssh -tt default "sudo make -C /vagrant localrootlessintegration" |
117 | | - |
118 | | - |
119 | | - # kernel 3.10 (frankenized), systemd 219 |
120 | | - centos7: |
121 | | - # nested virtualization is only available on macOS hosts |
122 | | - runs-on: macos-10.15 |
123 | | - timeout-minutes: 15 |
124 | | - # only run it if others have passed |
125 | | - needs: [test] |
126 | | - steps: |
127 | | - - uses: actions/checkout@v2 |
128 | | - |
129 | | - - name: "Cache ~/.vagrant.d/boxes, using hash of Vagrantfile.centos7" |
130 | | - uses: actions/cache@v2 |
131 | | - with: |
132 | | - path: ~/.vagrant.d/boxes |
133 | | - key: vagrant-${{ hashFiles('Vagrantfile.centos7') }} |
134 | | - |
135 | | - - name: prepare vagrant |
136 | | - run: | |
137 | | - ln -sf Vagrantfile.centos7 Vagrantfile |
138 | | - vagrant up |
139 | | - vagrant ssh-config >> ~/.ssh/config |
140 | | -
|
141 | | - - name: system info |
142 | | - run: ssh default 'rpm -q centos-release kernel systemd' |
143 | | - |
144 | | - - name: unit tests |
145 | | - run: ssh default 'sudo -i make -C /vagrant localunittest' |
146 | | - |
147 | | - - name: integration tests (fs cgroup driver) |
148 | | - run: ssh -tt default "sudo -i make -C /vagrant localintegration" |
149 | | - |
150 | | - - name: integration tests (systemd cgroup driver) |
151 | | - run: ssh -tt default "sudo -i make -C /vagrant localintegration RUNC_USE_SYSTEMD=1" |
152 | | - |
153 | | - - name: rootless integration |
154 | | - # FIXME: rootless is skipped because of EPERM on writing cgroup.procs |
155 | | - if: false |
156 | | - run: ssh default "sudo -i make -C /vagrant localrootlessintegration" |
157 | | - |
158 | 73 | # We need to continue support for 32-bit ARM. |
159 | 74 | # However, we do not have 32-bit ARM CI, so we use i386 for testing 32bit stuff. |
160 | 75 | # We are not interested in providing official support for i386. |
|
0 commit comments