diff --git a/.github/workflows/build_iso.yml b/.github/workflows/build_iso.yml index ea106b2..d416e2e 100644 --- a/.github/workflows/build_iso.yml +++ b/.github/workflows/build_iso.yml @@ -10,6 +10,9 @@ on: flatpaks_refs_dir: required: false type: string + suffix: + required: false + type: string jobs: load_vars: @@ -114,7 +117,7 @@ jobs: flatpak_remote_refs_dir: ${{ inputs.flatpaks_refs_dir }} secure_boot_key_url: ${{ needs.load_vars.outputs.SECURE_BOOT_KEY_URL }} enrollment_password: ${{ needs.load_vars.outputs.ENROLLMENT_PASSWORD }} - iso_name: build/${{ needs.load_vars.outputs.IMAGE_NAME }}-${{ matrix.version }}.iso + iso_name: build/${{ needs.load_vars.outputs.IMAGE_NAME }}-${{ matrix.version }}${{ inputs.suffix && format('-{0}', inputs.suffix || '') }}.iso - name: Save output id: save_output @@ -126,10 +129,10 @@ jobs: id: upload uses: actions/upload-artifact@v4 with: - name: ${{ needs.load_vars.outputs.IMAGE_NAME }}-${{ matrix.version }} + name: ${{ needs.load_vars.outputs.IMAGE_NAME }}-${{ matrix.version }}${{ inputs.suffix && format('-{0}', inputs.suffix || '') }} path: | - build/${{ needs.load_vars.outputs.IMAGE_NAME }}-${{ matrix.version }}.iso - build/${{ needs.load_vars.outputs.IMAGE_NAME }}-${{ matrix.version }}.iso-CHECKSUM + build/${{ needs.load_vars.outputs.IMAGE_NAME }}-${{ matrix.version }}${{ inputs.suffix && format('-{0}', inputs.suffix || '') }}.iso + build/${{ needs.load_vars.outputs.IMAGE_NAME }}-${{ matrix.version }}${{ inputs.suffix && format('-{0}', inputs.suffix || '') }}.iso-CHECKSUM if-no-files-found: error retention-days: 0 compression-level: 0 diff --git a/.github/workflows/test_deployment.yml b/.github/workflows/test_deployment.yml index f057a88..bdbaac2 100644 --- a/.github/workflows/test_deployment.yml +++ b/.github/workflows/test_deployment.yml @@ -7,6 +7,9 @@ on: parent_job_name: required: true type: string + suffix: + required: false + type: string jobs: load_vars: diff --git a/.github/workflows/test_iso.yml b/.github/workflows/test_iso.yml index 12cd326..033b6a4 100644 --- a/.github/workflows/test_iso.yml +++ b/.github/workflows/test_iso.yml @@ -6,7 +6,10 @@ on: type: string parent_job_name: required: true - type: string + type: string + suffix: + required: false + type: string jobs: load_vars: @@ -72,7 +75,7 @@ jobs: - name: Download generated ISO uses: actions/download-artifact@v4 with: - name: ${{ format('{0}-{1}', needs.load_vars.outputs.IMAGE_NAME, matrix.version) }} + name: ${{ format('{0}-{1}', needs.load_vars.outputs.IMAGE_NAME, matrix.version) }}${{ inputs.suffix && format('-{0}', inputs.suffix || '') }} - name: Run ISO checks run: | @@ -86,7 +89,7 @@ jobs: FLATPAK_REMOTE_REFS_DIR=${{ needs.load_vars.outputs.FLATPAK_REMOTE_REFS_DIR }} \ SECURE_BOOT_KEY_URL=${{ needs.load_vars.outputs.SECURE_BOOT_KEY_URL }} \ ENROLLMENT_PASSWORD=${{ needs.load_vars.outputs.ENROLLMENT_PASSWORD }} \ - ISO_NAME=${{ format('{0}-{1}', needs.load_vars.outputs.IMAGE_NAME, matrix.version) }}.iso + ISO_NAME=${{ format('{0}-{1}', needs.load_vars.outputs.IMAGE_NAME, matrix.version) }}${{ inputs.suffix && format('-{0}', inputs.suffix || '') }}.iso - name: Set status if: inputs.pr && always() diff --git a/.github/workflows/variables.yml b/.github/workflows/test_variables.yml similarity index 79% rename from .github/workflows/variables.yml rename to .github/workflows/test_variables.yml index e697fa0..2f9caaa 100644 --- a/.github/workflows/variables.yml +++ b/.github/workflows/test_variables.yml @@ -24,4 +24,7 @@ jobs: - name: Run test run: | - /bin/bash tests/repo/vars.sh \ No newline at end of file + apt-get update + apt-get install -y make + make test/repo/install-deps + make test/repo \ No newline at end of file diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 89e79d3..d7819f1 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -38,11 +38,32 @@ jobs: uses: ./.github/workflows/build_iso.yml with: pr: ${{ inputs.pr }} - parent_job_name: ${{ inputs.parent_job_name && format('{0} / ', inputs.parent_job_name) }}Build ISO + parent_job_name: ${{ inputs.parent_job_name && format('{0} / ', inputs.parent_job_name) }}Build ISO with Flatpaks flatpaks_refs_dir: /github/workspace/flatpak_refs + suffix: flatpaks - build_iso_no_flatpaks: - name: Build ISO without Flatpaks + test_iso_flatpaks: + name: Test ISO with Flatpaks + needs: + - build_iso_flatpaks + uses: ./.github/workflows/test_iso.yml + with: + pr: ${{ inputs.pr }} + parent_job_name: ${{ inputs.parent_job_name && format('{0} / ', inputs.parent_job_name) }}Test ISO with Flatpaks + suffix: flatpaks + + test_deployment_flatpaks: + name: Test Deployment with Flatpaks + needs: + - build_iso_flatpaks + uses: ./.github/workflows/test_deployment.yml + with: + pr: ${{ inputs.pr }} + parent_job_name: ${{ inputs.parent_job_name && format('{0} / ', inputs.parent_job_name) }}Test Deployment with Flatpaks + suffix: flatpaks + + build_iso: + name: Build ISO needs: - build_container uses: ./.github/workflows/build_iso.yml @@ -53,7 +74,7 @@ jobs: test_iso: name: Test ISO needs: - - build_iso_flatpaks + - build_iso uses: ./.github/workflows/test_iso.yml with: pr: ${{ inputs.pr }} @@ -62,7 +83,7 @@ jobs: test_deployment: name: Test Deployment needs: - - build_iso_flatpaks + - build_iso uses: ./.github/workflows/test_deployment.yml with: pr: ${{ inputs.pr }} diff --git a/test/repo/Makefile b/test/repo/Makefile index 90e4d56..3c395c3 100644 --- a/test/repo/Makefile +++ b/test/repo/Makefile @@ -6,4 +6,6 @@ $(REPO_TESTS): chmod +x $@ ./$@ +install-deps: + .PHONY: $(REPO_TESTS) \ No newline at end of file