Refactor
This commit is contained in:
		
							
								
								
									
										104
									
								
								.github/workflows/ubuntu.yml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										104
									
								
								.github/workflows/ubuntu.yml
									
									
									
									
										vendored
									
									
								
							| @@ -129,13 +129,13 @@ jobs: | ||||
|         name: test-end-to-end-genall-logs | ||||
|         path: /home/runner/.out-of-tree/logs/out-of-tree.log | ||||
|  | ||||
|   test-end-to-end-ubuntu: | ||||
|     name: End-to-End Testing (Ubuntu) | ||||
|   test-end-to-end-distros: | ||||
|     name: End-to-End Testing | ||||
|     runs-on: ubuntu-latest | ||||
|  | ||||
|     strategy: | ||||
|       matrix: | ||||
|         release: [12.04, 14.04, 16.04, 18.04, 20.04, 22.04] | ||||
|         os: [ { distro: Ubuntu, release: 12.04 }, distro: Ubuntu, release: 14.04 }, distro: Ubuntu, release: 16.04 }, distro: Ubuntu, release: 18.04 }, distro: Ubuntu, release: 20.04 }, distro: Ubuntu, release: 22.04 }, { distro: CentOS, release: 6 }, { distro: CentOS, release: 7 }, { distro: CentOS, release: 8 }, { distro: OracleLinux, release: 6 }, { distro: OracleLinux, release: 7 }, { distro: OracleLinux, release: 8 }, { distro: OracleLinux, release: 9 } ] | ||||
|  | ||||
|     steps: | ||||
|     - uses: actions/checkout@v1 | ||||
| @@ -148,7 +148,7 @@ jobs: | ||||
|         sudo apt-get update | ||||
|         sudo apt-get install qemu-system-x86 | ||||
|  | ||||
|     - name: End-to-End Testing [Ubuntu ${{ matrix.release }}] | ||||
|     - name: End-to-End Testing [${{ matrix.os.distro }} ${{ matrix.os.release }}] | ||||
|       run: | | ||||
|         mkdir test | ||||
|         cd test | ||||
| @@ -157,106 +157,18 @@ jobs: | ||||
|         echo 'type = "script"' >> .out-of-tree.toml | ||||
|         echo 'script = "script.sh"' >> .out-of-tree.toml | ||||
|         echo '[[supported_kernels]]' >> .out-of-tree.toml | ||||
|         echo 'distro_type = "Ubuntu"' >> .out-of-tree.toml | ||||
|         echo 'distro_release = "${{ matrix.release }}"' >> .out-of-tree.toml | ||||
|         echo 'distro_type = "${{ matrix.os.distro }}"' >> .out-of-tree.toml | ||||
|         echo 'distro_release = "${{ matrix.os.release }}"' >> .out-of-tree.toml | ||||
|         echo 'release_mask = ".*"' >> .out-of-tree.toml | ||||
|  | ||||
|         echo -e '#!/bin/sh\necho ok' >> script.sh | ||||
|  | ||||
|         ../out-of-tree --log-level=debug kernel list-remote --distro=Ubuntu --ver=${{ matrix.release }} | ||||
|         ../out-of-tree --log-level=debug kernel list-remote --distro=${{ matrix.os.distro }} --ver=${{ matrix.os.release }} | ||||
|         ../out-of-tree --log-level=debug kernel autogen --max=1 --shuffle | ||||
|         ../out-of-tree --log-level=debug pew --qemu-timeout=10m | ||||
|  | ||||
|     - name: Archive logs | ||||
|       uses: actions/upload-artifact@v3 | ||||
|       with: | ||||
|         name: test-end-to-end-ubuntu-${{ matrix.release }} | ||||
|         path: /home/runner/.out-of-tree/logs/out-of-tree.log | ||||
|  | ||||
|   test-end-to-end-centos: | ||||
|     name: End-to-End Testing (CentOS) | ||||
|     runs-on: ubuntu-latest | ||||
|  | ||||
|     strategy: | ||||
|       matrix: | ||||
|         release: [6, 7, 8] | ||||
|  | ||||
|     steps: | ||||
|     - uses: actions/checkout@v1 | ||||
|  | ||||
|     - name: Build | ||||
|       run: go build | ||||
|  | ||||
|     - name: Install dependencies for tests | ||||
|       run: | | ||||
|         sudo apt-get update | ||||
|         sudo apt-get install qemu-system-x86 | ||||
|  | ||||
|     - name: End-to-End Testing [Ubuntu ${{ matrix.release }}] | ||||
|       run: | | ||||
|         mkdir test | ||||
|         cd test | ||||
|  | ||||
|         echo 'name = "out-of-tree script"' >> .out-of-tree.toml | ||||
|         echo 'type = "script"' >> .out-of-tree.toml | ||||
|         echo 'script = "script.sh"' >> .out-of-tree.toml | ||||
|         echo '[[supported_kernels]]' >> .out-of-tree.toml | ||||
|         echo 'distro_type = "CentOS"' >> .out-of-tree.toml | ||||
|         echo 'distro_release = "${{ matrix.release }}"' >> .out-of-tree.toml | ||||
|         echo 'release_mask = ".*"' >> .out-of-tree.toml | ||||
|  | ||||
|         echo -e '#!/bin/sh\necho ok' >> script.sh | ||||
|  | ||||
|         ../out-of-tree --log-level=debug kernel list-remote --distro=CentOS --ver=${{ matrix.release }} | ||||
|         ../out-of-tree --log-level=debug kernel autogen --max=1 --shuffle | ||||
|         ../out-of-tree --log-level=debug pew --qemu-timeout=10m | ||||
|  | ||||
|     - name: Archive logs | ||||
|       uses: actions/upload-artifact@v3 | ||||
|       with: | ||||
|         name: test-end-to-end-centos-${{ matrix.release }} | ||||
|         path: /home/runner/.out-of-tree/logs/out-of-tree.log | ||||
|  | ||||
|   test-end-to-end-oracle-linux: | ||||
|     name: End-to-End Testing (Oracle Linux) | ||||
|     runs-on: ubuntu-latest | ||||
|  | ||||
|     strategy: | ||||
|       matrix: | ||||
|         release: [6, 7, 8, 9] | ||||
|  | ||||
|     steps: | ||||
|     - uses: actions/checkout@v1 | ||||
|  | ||||
|     - name: Build | ||||
|       run: go build | ||||
|  | ||||
|     - name: Install dependencies for tests | ||||
|       run: | | ||||
|         sudo apt-get update | ||||
|         sudo apt-get install qemu-system-x86 | ||||
|  | ||||
|     - name: End-to-End Testing [Ubuntu ${{ matrix.release }}] | ||||
|       run: | | ||||
|         mkdir test | ||||
|         cd test | ||||
|  | ||||
|         echo 'name = "out-of-tree script"' >> .out-of-tree.toml | ||||
|         echo 'type = "script"' >> .out-of-tree.toml | ||||
|         echo 'script = "script.sh"' >> .out-of-tree.toml | ||||
|         echo '[[supported_kernels]]' >> .out-of-tree.toml | ||||
|         echo 'distro_type = "OracleLinux"' >> .out-of-tree.toml | ||||
|         echo 'distro_release = "${{ matrix.release }}"' >> .out-of-tree.toml | ||||
|         echo 'release_mask = ".*"' >> .out-of-tree.toml | ||||
|  | ||||
|         echo -e '#!/bin/sh\necho ok' >> script.sh | ||||
|  | ||||
|         ../out-of-tree --log-level=debug kernel list-remote --distro=OracleLinux --ver=${{ matrix.release }} | ||||
|         ../out-of-tree --log-level=debug kernel autogen --max=1 --shuffle | ||||
|         ../out-of-tree --log-level=debug pew --qemu-timeout=10m | ||||
|  | ||||
|     - name: Archive logs | ||||
|       uses: actions/upload-artifact@v3 | ||||
|       with: | ||||
|         name: test-end-to-end-oraclelinux-${{ matrix.release }} | ||||
|         name: test-end-to-end-${{ matrix.os.distro }}-${{ matrix.os.release }} | ||||
|         path: /home/runner/.out-of-tree/logs/out-of-tree.log | ||||
|   | ||||
		Reference in New Issue
	
	Block a user