diff --git a/.github/build.yaml.gomplate b/.github/build.yaml.gomplate index bc258ff224f..26a62206066 100644 --- a/.github/build.yaml.gomplate +++ b/.github/build.yaml.gomplate @@ -72,6 +72,7 @@ {{{ $target := . }}} - name: Run make {{{ $target }}} run: | + {{{ if eq $target "deps" }}}export DOCKER_INSTALL=true{{{end}}} sudo -E make {{{ $target }}} {{{ if eq $target "deps" }}} {{{- if ne $config.luet_override "" }}} diff --git a/.github/config/pr.yaml b/.github/config/pr.yaml index 8b843c14daf..d76421e21a7 100644 --- a/.github/config/pr.yaml +++ b/.github/config/pr.yaml @@ -34,6 +34,7 @@ flavors: paths: - 'conf/**' - 'packages/**' + - 'tests/**' - 'make/**' - '.github/**' - 'Makefile' diff --git a/.github/workflows/build-examples-green-x86_64.yaml b/.github/workflows/build-examples-green-x86_64.yaml index 8daedc04e38..435155273a7 100644 --- a/.github/workflows/build-examples-green-x86_64.yaml +++ b/.github/workflows/build-examples-green-x86_64.yaml @@ -41,6 +41,7 @@ jobs: go-version: '^1.16' - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Build cos-official 🔧 shell: 'script -q -e -c "bash {0}"' @@ -81,6 +82,7 @@ jobs: go-version: '^1.16' - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Build scratch 🔧 shell: 'script -q -e -c "bash {0}"' @@ -121,6 +123,7 @@ jobs: go-version: '^1.16' - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Build standard 🔧 shell: 'script -q -e -c "bash {0}"' diff --git a/.github/workflows/build-master-blue-arm64.yaml b/.github/workflows/build-master-blue-arm64.yaml index 9a9120835f2..6aff7c11283 100644 --- a/.github/workflows/build-master-blue-arm64.yaml +++ b/.github/workflows/build-master-blue-arm64.yaml @@ -61,6 +61,7 @@ jobs: run: echo ${{ secrets.QUAY_PASSWORD }} | docker login -u ${{ secrets.QUAY_USERNAME }} --password-stdin quay.io - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Run make validate run: | @@ -115,6 +116,7 @@ jobs: - uses: actions/checkout@v2 - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Generate link for blue run: | @@ -194,6 +196,7 @@ jobs: password: ${{ secrets.QUAY_PASSWORD }} - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Download result for build uses: actions/download-artifact@v2 diff --git a/.github/workflows/build-master-blue-x86_64.yaml b/.github/workflows/build-master-blue-x86_64.yaml index 4fa99f1606b..ad1134ee5e4 100644 --- a/.github/workflows/build-master-blue-x86_64.yaml +++ b/.github/workflows/build-master-blue-x86_64.yaml @@ -59,6 +59,7 @@ jobs: run: echo ${{ secrets.QUAY_PASSWORD }} | docker login -u ${{ secrets.QUAY_USERNAME }} --password-stdin quay.io - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Run make validate run: | @@ -113,6 +114,7 @@ jobs: - uses: actions/checkout@v2 - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Generate link for blue run: | @@ -192,6 +194,7 @@ jobs: password: ${{ secrets.QUAY_PASSWORD }} - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Download result for build uses: actions/download-artifact@v2 diff --git a/.github/workflows/build-master-green-arm64.yaml b/.github/workflows/build-master-green-arm64.yaml index 75714cc9a69..3d0ede4abdd 100644 --- a/.github/workflows/build-master-green-arm64.yaml +++ b/.github/workflows/build-master-green-arm64.yaml @@ -61,6 +61,7 @@ jobs: run: echo ${{ secrets.QUAY_PASSWORD }} | docker login -u ${{ secrets.QUAY_USERNAME }} --password-stdin quay.io - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Run make validate run: | @@ -144,6 +145,7 @@ jobs: sudo apt-get install -y xorriso squashfs-tools mtools - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Export cos version run: | @@ -309,6 +311,7 @@ jobs: sudo apt-get install -y xorriso squashfs-tools mtools - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Tweak manifest and drop squashfs recovery run: | @@ -449,6 +452,7 @@ jobs: - uses: actions/checkout@v2 - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Generate link for green run: | @@ -527,6 +531,7 @@ jobs: password: ${{ secrets.QUAY_PASSWORD }} - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Download result for build uses: actions/download-artifact@v2 @@ -581,6 +586,7 @@ jobs: path: build - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Export cos version run: | diff --git a/.github/workflows/build-master-green-x86_64.yaml b/.github/workflows/build-master-green-x86_64.yaml index 9f3db7e4012..00dc1bd98fb 100644 --- a/.github/workflows/build-master-green-x86_64.yaml +++ b/.github/workflows/build-master-green-x86_64.yaml @@ -59,6 +59,7 @@ jobs: run: echo ${{ secrets.QUAY_PASSWORD }} | docker login -u ${{ secrets.QUAY_USERNAME }} --password-stdin quay.io - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Run make validate run: | @@ -142,6 +143,7 @@ jobs: sudo apt-get install -y xorriso squashfs-tools mtools - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Export cos version run: | @@ -420,6 +422,7 @@ jobs: sudo apt-get install -y xorriso squashfs-tools mtools - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Tweak manifest and drop squashfs recovery run: | @@ -673,6 +676,7 @@ jobs: - uses: actions/checkout@v2 - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Generate link for green run: | @@ -751,6 +755,7 @@ jobs: password: ${{ secrets.QUAY_PASSWORD }} - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Download result for build uses: actions/download-artifact@v2 @@ -805,6 +810,7 @@ jobs: path: build - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Export cos version run: | @@ -923,6 +929,7 @@ jobs: sudo cp -rfv .github/plugins/* /usr/bin/ - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Export cos version run: | @@ -960,6 +967,7 @@ jobs: sudo cp -rfv .github/plugins/* /usr/bin/ - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Export cos version run: | @@ -997,6 +1005,7 @@ jobs: sudo cp -rfv .github/plugins/* /usr/bin/ - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Export cos version run: | @@ -1051,6 +1060,7 @@ jobs: sudo cp -rfv .github/plugins/* /usr/bin/ - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Export cos version run: | diff --git a/.github/workflows/build-master-orange-arm64.yaml b/.github/workflows/build-master-orange-arm64.yaml index b4423908603..a5ef3cc7018 100644 --- a/.github/workflows/build-master-orange-arm64.yaml +++ b/.github/workflows/build-master-orange-arm64.yaml @@ -63,6 +63,7 @@ jobs: run: echo ${{ secrets.QUAY_PASSWORD }} | docker login -u ${{ secrets.QUAY_USERNAME }} --password-stdin quay.io - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Run make validate run: | @@ -117,6 +118,7 @@ jobs: - uses: actions/checkout@v2 - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Generate link for orange run: | @@ -196,6 +198,7 @@ jobs: password: ${{ secrets.QUAY_PASSWORD }} - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Download result for build uses: actions/download-artifact@v2 diff --git a/.github/workflows/build-master-orange-x86_64.yaml b/.github/workflows/build-master-orange-x86_64.yaml index 76bb9c4dde1..b88294ac06a 100644 --- a/.github/workflows/build-master-orange-x86_64.yaml +++ b/.github/workflows/build-master-orange-x86_64.yaml @@ -59,6 +59,7 @@ jobs: run: echo ${{ secrets.QUAY_PASSWORD }} | docker login -u ${{ secrets.QUAY_USERNAME }} --password-stdin quay.io - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Run make validate run: | @@ -113,6 +114,7 @@ jobs: - uses: actions/checkout@v2 - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Generate link for orange run: | @@ -192,6 +194,7 @@ jobs: password: ${{ secrets.QUAY_PASSWORD }} - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Download result for build uses: actions/download-artifact@v2 diff --git a/.github/workflows/build-nightly-blue-x86_64.yaml b/.github/workflows/build-nightly-blue-x86_64.yaml index eef7054e070..258e7a657a0 100644 --- a/.github/workflows/build-nightly-blue-x86_64.yaml +++ b/.github/workflows/build-nightly-blue-x86_64.yaml @@ -61,6 +61,7 @@ jobs: sudo cp -rfv .github/plugins/* /usr/bin/ - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Run make validate run: | @@ -113,6 +114,7 @@ jobs: path: build - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Export cos version run: | diff --git a/.github/workflows/build-nightly-green-x86_64.yaml b/.github/workflows/build-nightly-green-x86_64.yaml index c9f736a3ed0..2953475c408 100644 --- a/.github/workflows/build-nightly-green-x86_64.yaml +++ b/.github/workflows/build-nightly-green-x86_64.yaml @@ -61,6 +61,7 @@ jobs: sudo cp -rfv .github/plugins/* /usr/bin/ - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Run make validate run: | @@ -119,6 +120,7 @@ jobs: sudo apt-get install -y xorriso squashfs-tools mtools - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Export cos version run: | @@ -391,6 +393,7 @@ jobs: sudo apt-get install -y xorriso squashfs-tools mtools - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Tweak manifest and drop squashfs recovery run: | @@ -661,6 +664,7 @@ jobs: path: build - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Export cos version run: | diff --git a/.github/workflows/build-nightly-orange-x86_64.yaml b/.github/workflows/build-nightly-orange-x86_64.yaml index 6f11d304fa8..77e10d8beb8 100644 --- a/.github/workflows/build-nightly-orange-x86_64.yaml +++ b/.github/workflows/build-nightly-orange-x86_64.yaml @@ -61,6 +61,7 @@ jobs: sudo cp -rfv .github/plugins/* /usr/bin/ - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Run make validate run: | @@ -113,6 +114,7 @@ jobs: path: build - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Export cos version run: | diff --git a/.github/workflows/build-pr-blue-arm64.yaml b/.github/workflows/build-pr-blue-arm64.yaml index 5fec0cf338a..3392bd59260 100644 --- a/.github/workflows/build-pr-blue-arm64.yaml +++ b/.github/workflows/build-pr-blue-arm64.yaml @@ -60,6 +60,7 @@ jobs: sudo cp -rfv .github/plugins/* /usr/bin/ - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Run make validate run: | diff --git a/.github/workflows/build-pr-blue-x86_64.yaml b/.github/workflows/build-pr-blue-x86_64.yaml index 350686d41ad..ef489d294f3 100644 --- a/.github/workflows/build-pr-blue-x86_64.yaml +++ b/.github/workflows/build-pr-blue-x86_64.yaml @@ -4,6 +4,7 @@ on: paths: - conf/** - packages/** + - tests/** - make/** - .github/** - Makefile @@ -62,6 +63,7 @@ jobs: sudo cp -rfv .github/plugins/* /usr/bin/ - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Run make validate run: | diff --git a/.github/workflows/build-pr-green-arm64.yaml b/.github/workflows/build-pr-green-arm64.yaml index 0ee1d89228e..961cd5ad8e3 100644 --- a/.github/workflows/build-pr-green-arm64.yaml +++ b/.github/workflows/build-pr-green-arm64.yaml @@ -60,6 +60,7 @@ jobs: sudo cp -rfv .github/plugins/* /usr/bin/ - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Run make validate run: | @@ -130,6 +131,7 @@ jobs: sudo apt-get install -y xorriso squashfs-tools mtools - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Export cos version run: | @@ -295,6 +297,7 @@ jobs: sudo apt-get install -y xorriso squashfs-tools mtools - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Tweak manifest and drop squashfs recovery run: | @@ -458,6 +461,7 @@ jobs: path: build - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Export cos version run: | diff --git a/.github/workflows/build-pr-green-x86_64.yaml b/.github/workflows/build-pr-green-x86_64.yaml index 4916a6a2a7f..be6b705b3e6 100644 --- a/.github/workflows/build-pr-green-x86_64.yaml +++ b/.github/workflows/build-pr-green-x86_64.yaml @@ -4,6 +4,7 @@ on: paths: - conf/** - packages/** + - tests/** - make/** - .github/** - Makefile @@ -62,6 +63,7 @@ jobs: sudo cp -rfv .github/plugins/* /usr/bin/ - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Run make validate run: | @@ -132,6 +134,7 @@ jobs: sudo apt-get install -y xorriso squashfs-tools mtools - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Export cos version run: | @@ -410,6 +413,7 @@ jobs: sudo apt-get install -y xorriso squashfs-tools mtools - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Tweak manifest and drop squashfs recovery run: | @@ -686,6 +690,7 @@ jobs: path: build - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Export cos version run: | diff --git a/.github/workflows/build-pr-orange-arm64.yaml b/.github/workflows/build-pr-orange-arm64.yaml index eca5f901faf..5b0ddbf7331 100644 --- a/.github/workflows/build-pr-orange-arm64.yaml +++ b/.github/workflows/build-pr-orange-arm64.yaml @@ -62,6 +62,7 @@ jobs: sudo cp -rfv .github/plugins/* /usr/bin/ - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Run make validate run: | diff --git a/.github/workflows/build-pr-orange-x86_64.yaml b/.github/workflows/build-pr-orange-x86_64.yaml index 886d25c1c87..6316643c466 100644 --- a/.github/workflows/build-pr-orange-x86_64.yaml +++ b/.github/workflows/build-pr-orange-x86_64.yaml @@ -4,6 +4,7 @@ on: paths: - conf/** - packages/** + - tests/** - make/** - .github/** - Makefile @@ -62,6 +63,7 @@ jobs: sudo cp -rfv .github/plugins/* /usr/bin/ - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Run make validate run: | diff --git a/.github/workflows/build-releases-blue-arm64.yaml b/.github/workflows/build-releases-blue-arm64.yaml index a0191cd6524..26c58609791 100644 --- a/.github/workflows/build-releases-blue-arm64.yaml +++ b/.github/workflows/build-releases-blue-arm64.yaml @@ -61,6 +61,7 @@ jobs: run: echo ${{ secrets.QUAY_PASSWORD }} | docker login -u ${{ secrets.QUAY_USERNAME }} --password-stdin quay.io - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Run make validate run: | @@ -115,6 +116,7 @@ jobs: - uses: actions/checkout@v2 - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Generate link for blue run: | @@ -194,6 +196,7 @@ jobs: password: ${{ secrets.QUAY_PASSWORD }} - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Download result for build uses: actions/download-artifact@v2 diff --git a/.github/workflows/build-releases-blue-x86_64.yaml b/.github/workflows/build-releases-blue-x86_64.yaml index 029ce9aecea..df94b152fac 100644 --- a/.github/workflows/build-releases-blue-x86_64.yaml +++ b/.github/workflows/build-releases-blue-x86_64.yaml @@ -59,6 +59,7 @@ jobs: run: echo ${{ secrets.QUAY_PASSWORD }} | docker login -u ${{ secrets.QUAY_USERNAME }} --password-stdin quay.io - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Run make validate run: | @@ -113,6 +114,7 @@ jobs: - uses: actions/checkout@v2 - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Generate link for blue run: | @@ -192,6 +194,7 @@ jobs: password: ${{ secrets.QUAY_PASSWORD }} - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Download result for build uses: actions/download-artifact@v2 diff --git a/.github/workflows/build-releases-green-arm64.yaml b/.github/workflows/build-releases-green-arm64.yaml index fbda48df645..0f34dfe9539 100644 --- a/.github/workflows/build-releases-green-arm64.yaml +++ b/.github/workflows/build-releases-green-arm64.yaml @@ -61,6 +61,7 @@ jobs: run: echo ${{ secrets.QUAY_PASSWORD }} | docker login -u ${{ secrets.QUAY_USERNAME }} --password-stdin quay.io - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Run make validate run: | @@ -144,6 +145,7 @@ jobs: sudo apt-get install -y xorriso squashfs-tools mtools - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Export cos version run: | @@ -309,6 +311,7 @@ jobs: sudo apt-get install -y xorriso squashfs-tools mtools - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Tweak manifest and drop squashfs recovery run: | @@ -449,6 +452,7 @@ jobs: - uses: actions/checkout@v2 - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Generate link for green run: | @@ -527,6 +531,7 @@ jobs: password: ${{ secrets.QUAY_PASSWORD }} - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Download result for build uses: actions/download-artifact@v2 @@ -569,6 +574,7 @@ jobs: - uses: actions/checkout@v2 - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Export cos version run: | @@ -652,6 +658,7 @@ jobs: path: build - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Export cos version run: | diff --git a/.github/workflows/build-releases-green-x86_64.yaml b/.github/workflows/build-releases-green-x86_64.yaml index 365359d626b..ee0d8a285b4 100644 --- a/.github/workflows/build-releases-green-x86_64.yaml +++ b/.github/workflows/build-releases-green-x86_64.yaml @@ -59,6 +59,7 @@ jobs: run: echo ${{ secrets.QUAY_PASSWORD }} | docker login -u ${{ secrets.QUAY_USERNAME }} --password-stdin quay.io - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Run make validate run: | @@ -142,6 +143,7 @@ jobs: sudo apt-get install -y xorriso squashfs-tools mtools - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Export cos version run: | @@ -420,6 +422,7 @@ jobs: sudo apt-get install -y xorriso squashfs-tools mtools - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Tweak manifest and drop squashfs recovery run: | @@ -673,6 +676,7 @@ jobs: - uses: actions/checkout@v2 - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Generate link for green run: | @@ -751,6 +755,7 @@ jobs: password: ${{ secrets.QUAY_PASSWORD }} - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Download result for build uses: actions/download-artifact@v2 @@ -795,6 +800,7 @@ jobs: - uses: actions/checkout@v2 - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Export cos version run: | @@ -892,6 +898,7 @@ jobs: path: build - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Export cos version run: | @@ -1000,6 +1007,7 @@ jobs: - uses: actions/checkout@v2 - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Public IP id: ip @@ -1037,6 +1045,7 @@ jobs: sudo cp -rfv .github/plugins/* /usr/bin/ - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Export cos version run: | @@ -1074,6 +1083,7 @@ jobs: sudo cp -rfv .github/plugins/* /usr/bin/ - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Export cos version run: | @@ -1111,6 +1121,7 @@ jobs: sudo cp -rfv .github/plugins/* /usr/bin/ - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Export cos version run: | @@ -1165,6 +1176,7 @@ jobs: sudo cp -rfv .github/plugins/* /usr/bin/ - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Export cos version run: | @@ -1204,6 +1216,7 @@ jobs: - uses: actions/checkout@v2 - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Export cos version run: | diff --git a/.github/workflows/build-releases-orange-arm64.yaml b/.github/workflows/build-releases-orange-arm64.yaml index e59c21981b4..6bd5872d142 100644 --- a/.github/workflows/build-releases-orange-arm64.yaml +++ b/.github/workflows/build-releases-orange-arm64.yaml @@ -63,6 +63,7 @@ jobs: run: echo ${{ secrets.QUAY_PASSWORD }} | docker login -u ${{ secrets.QUAY_USERNAME }} --password-stdin quay.io - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Run make validate run: | @@ -117,6 +118,7 @@ jobs: - uses: actions/checkout@v2 - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Generate link for orange run: | @@ -196,6 +198,7 @@ jobs: password: ${{ secrets.QUAY_PASSWORD }} - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Download result for build uses: actions/download-artifact@v2 diff --git a/.github/workflows/build-releases-orange-x86_64.yaml b/.github/workflows/build-releases-orange-x86_64.yaml index 9dae59cb255..99883ba68c6 100644 --- a/.github/workflows/build-releases-orange-x86_64.yaml +++ b/.github/workflows/build-releases-orange-x86_64.yaml @@ -59,6 +59,7 @@ jobs: run: echo ${{ secrets.QUAY_PASSWORD }} | docker login -u ${{ secrets.QUAY_USERNAME }} --password-stdin quay.io - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Run make validate run: | @@ -113,6 +114,7 @@ jobs: - uses: actions/checkout@v2 - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Generate link for orange run: | @@ -192,6 +194,7 @@ jobs: password: ${{ secrets.QUAY_PASSWORD }} - name: Run make deps run: | + export DOCKER_INSTALL=true sudo -E make deps - name: Download result for build uses: actions/download-artifact@v2 diff --git a/scripts/get_luet.sh b/scripts/get_luet.sh index ae69241a337..6bf515d6f24 100755 --- a/scripts/get_luet.sh +++ b/scripts/get_luet.sh @@ -7,11 +7,6 @@ fi set -ex export LUET_NOLOCK=true -LUET_VERSION=$(curl -s https://api.github.com/repos/mudler/luet/releases/latest | grep tag_name | awk '{ print $2 }' | sed -e 's/\"//g' -e 's/,//g' || echo "0.9.24" ) -if [[ -z "${LUET_VERSION}" ]]; then - LUET_VERSION="0.22.7" -fi - LUET_ROOTFS=${LUET_ROOTFS:-/} LUET_DATABASE_PATH=${LUET_DATABASE_PATH:-/var/luet/db} LUET_DATABASE_ENGINE=${LUET_DATABASE_ENGINE:-boltdb} @@ -19,6 +14,8 @@ LUET_CONFIG_PROTECT=${LUET_CONFIG_PROTECT:-1} LUET_PACKAGE="${LUET_PACKAGE:-toolchain/luet}" LUET_ARCH="${LUET_ARCH:-x86_64}" LUET_INSTALL_FROM_COS_REPO="${LUET_INSTALL_FROM_COS_REPO:-true}" +# This is the luet bootstrap version. The latest available will be pulled later on +LUET_VERSION="${LUET_VERSION:-0.30.2}" if [ -z "$LUET_ARCH" ]; then LUET_ARCH=$(uname -m) @@ -33,7 +30,29 @@ case $LUET_ARCH in ;; esac -curl -L https://github.com/mudler/luet/releases/download/${LUET_VERSION}/luet-${LUET_VERSION}-linux-${LUET_ARCH} --output luet +if [[ "$LUET_ARCH" != "amd64" ]]; then + REPO_URL="quay.io/costoolkit/releases-green-$LUET_ARCH" +else + REPO_URL="quay.io/costoolkit/releases-green" +fi + +if [[ "$DOCKER_INSTALL" == "true" ]]; then + _DOCKER_IMAGE="$REPO_URL:luet-toolchain-$LUET_VERSION" + echo "Using luet bootstrap version from docker image: ${_DOCKER_IMAGE}" + docker run --entrypoint /usr/bin/luet --name luet ${_DOCKER_IMAGE} --version + docker cp luet:/usr/bin/luet ./ +else + _LUET="luet-${LUET_VERSION}-linux-${LUET_ARCH}" + _LUET_URL="https://github.com/mudler/luet/releases/download/${LUET_VERSION}/${_LUET}" + _LUET_CHECKSUMS="https://github.com/mudler/luet/releases/download/${LUET_VERSION}/luet-${LUET_VERSION}-checksums.txt" + echo "Using luet bootstrap version from URL: ${_LUET_URL}" + curl -L $_LUET_CHECKSUMS --output checksums.txt + curl -L $_LUET_URL --output luet + sha=$(cat checksums.txt | grep ${_LUET} | awk '{ print $1 }') + echo "$sha luet" | sha256sum -c + rm -rf checksum.txt +fi + chmod +x luet mkdir -p /etc/luet/repos.conf.d || true @@ -41,11 +60,6 @@ mkdir -p $LUET_DATABASE_PATH || true mkdir -p /var/tmp/luet || true if [[ "$LUET_INSTALL_FROM_COS_REPO" == "true" ]]; then - if [[ "$LUET_ARCH" != "amd64" ]]; then - REPO_URL="quay.io/costoolkit/releases-green-$LUET_ARCH" - else - REPO_URL="quay.io/costoolkit/releases-green" - fi cat > /etc/luet/luet.yaml < boot from cd, CD empty -> boot from disk + BeforeEach(func() { + // Assert we are booting from CD before running the tests + By("Making sure we booted from CD") + ExpectWithOffset(1, s.BootFrom()).To(Equal(sut.LiveCD)) + out, err := s.Command("grep /dev/sr /etc/mtab") + Expect(err).ToNot(HaveOccurred()) + Expect(out).To(ContainSubstring("iso9660")) + out, err = s.Command("df -h /") + Expect(err).ToNot(HaveOccurred()) + Expect(out).To(ContainSubstring("LiveOS_rootfs")) + s.EmptyDisk("/dev/sda") + _, _ = s.Command("sync") + }) + AfterEach(func() { + if CurrentGinkgoTestDescription().Failed { + s.GatherAllLogs() + } + }) + // Commented because there is only a single active test, hence restoring CD before + // after rebooting is not needed. + /*AfterEach(func() { + if CurrentGinkgoTestDescription().Failed { + s.GatherAllLogs() + } + // Store COS iso path + s.SetCOSCDLocation() + // Set Cos CD in the drive + s.RestoreCOSCD() + By("Reboot to make sure we boot from CD") + s.Reboot() + })*/ + Context("partition layout tests", func() { + Context("with partition layout", func() { + It("Forcing GPT", func() { + err := s.SendFile("../assets/layout.yaml", "/usr/local/layout.yaml", "0770") + By("Running the elemental install with a layout file") + Expect(err).To(BeNil()) + out, err := s.Command("elemental install --force-gpt --partition-layout /usr/local/layout.yaml /dev/sda") + fmt.Printf(out) + Expect(err).To(BeNil()) + Expect(out).To(ContainSubstring("Copying COS_ACTIVE image...")) + Expect(out).To(ContainSubstring("Installing GRUB..")) + Expect(out).To(ContainSubstring("Copying COS_PASSIVE image...")) + Expect(out).To(ContainSubstring("Mounting disk partitions")) + Expect(out).To(ContainSubstring("Partitioning device...")) + + // This section of the test is flaky in our CI w/EFI. Commenting it out for the time being + PContext("reboots successfully into installed system", func() { + // Remove iso so we boot directly from the disk + s.EjectCOSCD() + // Reboot so we boot into the just installed cos + s.Reboot() + By("Checking we booted from the installed cOS") + ExpectWithOffset(1, s.BootFrom()).To(Equal(sut.Active)) + // check partition values + // Values have to match the yaml under ../assets/layout.yaml + // That is the file that the installer uses so partitions should match those values + disk := s.GetDiskLayout("/dev/sda") + + for _, part := range []sut.PartitionEntry{ + { + Label: "COS_STATE", + Size: 8192, + FsType: sut.Ext4, + }, + { + Label: "COS_OEM", + Size: 10, + FsType: sut.Ext4, + }, + { + Label: "COS_RECOVERY", + Size: 4000, + FsType: sut.Ext2, + }, + { + Label: "COS_PERSISTENT", + Size: 100, + FsType: sut.Ext2, + }, + } { + CheckPartitionValues(disk, part) + } + }) + }) + // Marked as pending to reduce the number of efi tests. VBox efi support is + // not good enough to run extensive tests + PIt("Not forcing GPT", func() { + err := s.SendFile("../assets/layout.yaml", "/usr/local/layout.yaml", "0770") + By("Running the elemental install with a layout file") + Expect(err).To(BeNil()) + out, err := s.Command("elemental install --partition-layout /usr/local/layout.yaml /dev/sda") + Expect(err).To(BeNil()) + Expect(out).To(ContainSubstring("Copying COS_ACTIVE image...")) + Expect(out).To(ContainSubstring("Installing GRUB..")) + Expect(out).To(ContainSubstring("Copying COS_PASSIVE image...")) + Expect(out).To(ContainSubstring("Mounting disk partitions")) + Expect(out).To(ContainSubstring("Partitioning device...")) + // Remove iso so we boot directly from the disk + s.EjectCOSCD() + // Reboot so we boot into the just installed cos + s.Reboot() + By("Checking we booted from the installed cOS") + ExpectWithOffset(1, s.BootFrom()).To(Equal(sut.Active)) + // check partition values + // Values have to match the yaml under ../assets/layout.yaml + // That is the file that the installer uses so partitions should match those values + disk := s.GetDiskLayout("/dev/sda") + + for _, part := range []sut.PartitionEntry{ + { + Label: "COS_STATE", + Size: 8192, + FsType: sut.Ext4, + }, + { + Label: "COS_OEM", + Size: 10, + FsType: sut.Ext4, + }, + { + Label: "COS_RECOVERY", + Size: 4000, + FsType: sut.Ext2, + }, + { + Label: "COS_PERSISTENT", + Size: 100, + FsType: sut.Ext2, + }, + } { + CheckPartitionValues(disk, part) + } + }) + }) + }) + // Marked as pending to reduce the number of efi tests. VBox efi support is + // not good enough to run extensive tests + PContext("install source tests", func() { + It("from iso", func() { + By("Running the elemental install") + out, err := s.Command("elemental install /dev/sda") + Expect(err).To(BeNil()) + Expect(out).To(ContainSubstring("Copying COS_ACTIVE image...")) + Expect(out).To(ContainSubstring("Installing GRUB..")) + Expect(out).To(ContainSubstring("Copying COS_PASSIVE image")) + Expect(out).To(ContainSubstring("Copying COS_SYSTEM image")) + Expect(out).To(ContainSubstring("Mounting disk partitions")) + Expect(out).To(ContainSubstring("Partitioning device...")) + // Remove iso so we boot directly from the disk + s.EjectCOSCD() + // Reboot so we boot into the just installed cos + s.Reboot() + By("Checking we booted from the installed cOS") + ExpectWithOffset(1, s.BootFrom()).To(Equal(sut.Active)) + }) + PIt("from url", func() {}) + It("from docker image", func() { + By("Running the elemental install") + out, err := s.Command(fmt.Sprintf("elemental install --docker-image %s:cos-system-%s /dev/sda", s.GreenRepo, s.TestVersion)) + Expect(err).To(BeNil()) + Expect(out).To(ContainSubstring("Copying COS_ACTIVE image...")) + Expect(out).To(ContainSubstring("Installing GRUB..")) + Expect(out).To(ContainSubstring("Copying COS_PASSIVE image...")) + Expect(out).To(ContainSubstring("Mounting disk partitions")) + Expect(out).To(ContainSubstring("Partitioning device...")) + s.EjectCOSCD() + // Reboot so we boot into the just installed cos + s.Reboot() + By("Checking we booted from the installed cOS") + ExpectWithOffset(1, s.BootFrom()).To(Equal(sut.Active)) + Expect(s.GetOSRelease("VERSION")).To(Equal(s.TestVersion)) + }) + }) + // Marked as pending to reduce the number of efi tests. VBox efi support is + // not good enough to run extensive tests + PContext("efi/gpt tests", func() { + It("forces gpt", func() { + By("Running the installer") + out, err := s.Command("elemental install --force-gpt /dev/sda") + Expect(err).To(BeNil()) + Expect(out).To(ContainSubstring("Copying COS_ACTIVE image...")) + Expect(out).To(ContainSubstring("Installing GRUB..")) + Expect(out).To(ContainSubstring("Copying COS_PASSIVE image...")) + Expect(out).To(ContainSubstring("Mounting disk partitions")) + Expect(out).To(ContainSubstring("Partitioning device...")) + // Remove iso so we boot directly from the disk + s.EjectCOSCD() + // Reboot so we boot into the just installed cos + s.Reboot() + By("Checking we booted from the installed cOS") + ExpectWithOffset(1, s.BootFrom()).To(Equal(sut.Active)) + }) + It("forces efi", func() { + By("Running the installer") + out, err := s.Command("elemental install --force-efi /dev/sda") + Expect(err).To(BeNil()) + Expect(out).To(ContainSubstring("Copying COS_ACTIVE image...")) + Expect(out).To(ContainSubstring("Installing GRUB..")) + Expect(out).To(ContainSubstring("Copying COS_PASSIVE image...")) + Expect(out).To(ContainSubstring("Mounting disk partitions")) + Expect(out).To(ContainSubstring("Partitioning device...")) + // Remove iso so we boot directly from the disk + s.EjectCOSCD() + // Reboot so we boot into the just installed cos + s.Reboot() + // We are on an efi system, should boot from active + By("Checking we booted from Active partition") + ExpectWithOffset(1, s.BootFrom()).To(Equal(sut.Active)) + }) + }) + }) +}) diff --git a/tests/installer/installer_test.go b/tests/installer/installer_test.go index 80a0b6c32ca..faff4b71c6d 100644 --- a/tests/installer/installer_test.go +++ b/tests/installer/installer_test.go @@ -8,13 +8,6 @@ import ( "github.com/rancher-sandbox/cOS/tests/sut" ) -func CheckPartitionValues(diskLayout sut.DiskLayout, entry sut.PartitionEntry) { - part, err := diskLayout.GetPartition(entry.Label) - Expect(err).To(BeNil()) - Expect((part.Size / 1024) / 1024).To(Equal(entry.Size)) - Expect(part.FsType).To(Equal(entry.FsType)) -} - var _ = Describe("cOS Installer tests", func() { var s *sut.SUT @@ -43,11 +36,13 @@ var _ = Describe("cOS Installer tests", func() { Expect(err).ToNot(HaveOccurred()) Expect(out).To(ContainSubstring("LiveOS_rootfs")) }) + AfterEach(func() { if CurrentGinkgoTestDescription().Failed { s.GatherAllLogs() } }) + Context("install source tests", func() { It("from iso", func() { By("Running the elemental install") @@ -82,6 +77,7 @@ var _ = Describe("cOS Installer tests", func() { Expect(s.GetOSRelease("VERSION")).To(Equal(s.TestVersion)) }) }) + Context("partition layout tests", func() { Context("with partition layout", func() { It("Forcing GPT", func() { @@ -130,6 +126,7 @@ var _ = Describe("cOS Installer tests", func() { CheckPartitionValues(disk, part) } }) + It("No GPT", func() { err := s.SendFile("../assets/layout.yaml", "/usr/local/layout.yaml", "0770") By("Running the elemental install with a layout file") @@ -178,6 +175,7 @@ var _ = Describe("cOS Installer tests", func() { }) }) }) + Context("efi/gpt tests", func() { It("forces gpt", func() { By("Running the installer") @@ -193,6 +191,7 @@ var _ = Describe("cOS Installer tests", func() { By("Checking we booted from the installed cOS") ExpectWithOffset(1, s.BootFrom()).To(Equal(sut.Active)) }) + It("forces efi", func() { By("Running the installer") out, err := s.Command("elemental install --force-efi /dev/sda") @@ -232,218 +231,6 @@ var _ = Describe("cOS Installer tests", func() { out, err = s.Command("hostname") Expect(err).To(BeNil()) Expect(out).To(ContainSubstring("testhostname")) - - }) - }) - }) - Context("Using efi", func() { - // EFI variant tests is not able to set the boot order and there is no plan to let the user do so according to virtualbox - // So we need to manually eject/insert the cd to force the boot order. CD inserted -> boot from cd, CD empty -> boot from disk - BeforeEach(func() { - // Assert we are booting from CD before running the tests - By("Making sure we booted from CD") - ExpectWithOffset(1, s.BootFrom()).To(Equal(sut.LiveCD)) - out, err := s.Command("grep /dev/sr /etc/mtab") - Expect(err).ToNot(HaveOccurred()) - Expect(out).To(ContainSubstring("iso9660")) - out, err = s.Command("df -h /") - Expect(err).ToNot(HaveOccurred()) - Expect(out).To(ContainSubstring("LiveOS_rootfs")) - s.EmptyDisk("/dev/sda") - _, _ = s.Command("sync") - }) - AfterEach(func() { - if CurrentGinkgoTestDescription().Failed { - s.GatherAllLogs() - } - }) - // Commented because there is only a single active test, hence restoring CD before - // after rebooting is not needed. - /*AfterEach(func() { - if CurrentGinkgoTestDescription().Failed { - s.GatherAllLogs() - } - // Store COS iso path - s.SetCOSCDLocation() - // Set Cos CD in the drive - s.RestoreCOSCD() - By("Reboot to make sure we boot from CD") - s.Reboot() - })*/ - Context("partition layout tests", func() { - Context("with partition layout", func() { - It("Forcing GPT", func() { - err := s.SendFile("../assets/layout.yaml", "/usr/local/layout.yaml", "0770") - By("Running the elemental install with a layout file") - Expect(err).To(BeNil()) - out, err := s.Command("elemental install --force-gpt --partition-layout /usr/local/layout.yaml /dev/sda") - fmt.Printf(out) - Expect(err).To(BeNil()) - Expect(out).To(ContainSubstring("Copying COS_ACTIVE image...")) - Expect(out).To(ContainSubstring("Installing GRUB..")) - Expect(out).To(ContainSubstring("Copying COS_PASSIVE image...")) - Expect(out).To(ContainSubstring("Mounting disk partitions")) - Expect(out).To(ContainSubstring("Partitioning device...")) - // Remove iso so we boot directly from the disk - s.EjectCOSCD() - // Reboot so we boot into the just installed cos - s.Reboot() - By("Checking we booted from the installed cOS") - ExpectWithOffset(1, s.BootFrom()).To(Equal(sut.Active)) - // check partition values - // Values have to match the yaml under ../assets/layout.yaml - // That is the file that the installer uses so partitions should match those values - disk := s.GetDiskLayout("/dev/sda") - - for _, part := range []sut.PartitionEntry{ - { - Label: "COS_STATE", - Size: 8192, - FsType: sut.Ext4, - }, - { - Label: "COS_OEM", - Size: 10, - FsType: sut.Ext4, - }, - { - Label: "COS_RECOVERY", - Size: 4000, - FsType: sut.Ext2, - }, - { - Label: "COS_PERSISTENT", - Size: 100, - FsType: sut.Ext2, - }, - } { - CheckPartitionValues(disk, part) - } - }) - // Marked as pending to reduce the number of efi tests. VBox efi support is - // not good enough to run extensive tests - PIt("Not forcing GPT", func() { - err := s.SendFile("../assets/layout.yaml", "/usr/local/layout.yaml", "0770") - By("Running the elemental install with a layout file") - Expect(err).To(BeNil()) - out, err := s.Command("elemental install --partition-layout /usr/local/layout.yaml /dev/sda") - Expect(err).To(BeNil()) - Expect(out).To(ContainSubstring("Copying COS_ACTIVE image...")) - Expect(out).To(ContainSubstring("Installing GRUB..")) - Expect(out).To(ContainSubstring("Copying COS_PASSIVE image...")) - Expect(out).To(ContainSubstring("Mounting disk partitions")) - Expect(out).To(ContainSubstring("Partitioning device...")) - // Remove iso so we boot directly from the disk - s.EjectCOSCD() - // Reboot so we boot into the just installed cos - s.Reboot() - By("Checking we booted from the installed cOS") - ExpectWithOffset(1, s.BootFrom()).To(Equal(sut.Active)) - // check partition values - // Values have to match the yaml under ../assets/layout.yaml - // That is the file that the installer uses so partitions should match those values - disk := s.GetDiskLayout("/dev/sda") - - for _, part := range []sut.PartitionEntry{ - { - Label: "COS_STATE", - Size: 8192, - FsType: sut.Ext4, - }, - { - Label: "COS_OEM", - Size: 10, - FsType: sut.Ext4, - }, - { - Label: "COS_RECOVERY", - Size: 4000, - FsType: sut.Ext2, - }, - { - Label: "COS_PERSISTENT", - Size: 100, - FsType: sut.Ext2, - }, - } { - CheckPartitionValues(disk, part) - } - }) - }) - }) - // Marked as pending to reduce the number of efi tests. VBox efi support is - // not good enough to run extensive tests - PContext("install source tests", func() { - It("from iso", func() { - By("Running the elemental install") - out, err := s.Command("elemental install /dev/sda") - Expect(err).To(BeNil()) - Expect(out).To(ContainSubstring("Copying COS_ACTIVE image...")) - Expect(out).To(ContainSubstring("Installing GRUB..")) - Expect(out).To(ContainSubstring("Copying COS_PASSIVE image")) - Expect(out).To(ContainSubstring("Copying COS_SYSTEM image")) - Expect(out).To(ContainSubstring("Mounting disk partitions")) - Expect(out).To(ContainSubstring("Partitioning device...")) - // Remove iso so we boot directly from the disk - s.EjectCOSCD() - // Reboot so we boot into the just installed cos - s.Reboot() - By("Checking we booted from the installed cOS") - ExpectWithOffset(1, s.BootFrom()).To(Equal(sut.Active)) - }) - PIt("from url", func() {}) - It("from docker image", func() { - By("Running the elemental install") - out, err := s.Command(fmt.Sprintf("elemental install --docker-image %s:cos-system-%s /dev/sda", s.GreenRepo, s.TestVersion)) - Expect(err).To(BeNil()) - Expect(out).To(ContainSubstring("Copying COS_ACTIVE image...")) - Expect(out).To(ContainSubstring("Installing GRUB..")) - Expect(out).To(ContainSubstring("Copying COS_PASSIVE image...")) - Expect(out).To(ContainSubstring("Mounting disk partitions")) - Expect(out).To(ContainSubstring("Partitioning device...")) - s.EjectCOSCD() - // Reboot so we boot into the just installed cos - s.Reboot() - By("Checking we booted from the installed cOS") - ExpectWithOffset(1, s.BootFrom()).To(Equal(sut.Active)) - Expect(s.GetOSRelease("VERSION")).To(Equal(s.TestVersion)) - }) - }) - // Marked as pending to reduce the number of efi tests. VBox efi support is - // not good enough to run extensive tests - PContext("efi/gpt tests", func() { - It("forces gpt", func() { - By("Running the installer") - out, err := s.Command("elemental install --force-gpt /dev/sda") - Expect(err).To(BeNil()) - Expect(out).To(ContainSubstring("Copying COS_ACTIVE image...")) - Expect(out).To(ContainSubstring("Installing GRUB..")) - Expect(out).To(ContainSubstring("Copying COS_PASSIVE image...")) - Expect(out).To(ContainSubstring("Mounting disk partitions")) - Expect(out).To(ContainSubstring("Partitioning device...")) - // Remove iso so we boot directly from the disk - s.EjectCOSCD() - // Reboot so we boot into the just installed cos - s.Reboot() - By("Checking we booted from the installed cOS") - ExpectWithOffset(1, s.BootFrom()).To(Equal(sut.Active)) - }) - It("forces efi", func() { - By("Running the installer") - out, err := s.Command("elemental install --force-efi /dev/sda") - Expect(err).To(BeNil()) - Expect(out).To(ContainSubstring("Copying COS_ACTIVE image...")) - Expect(out).To(ContainSubstring("Installing GRUB..")) - Expect(out).To(ContainSubstring("Copying COS_PASSIVE image...")) - Expect(out).To(ContainSubstring("Mounting disk partitions")) - Expect(out).To(ContainSubstring("Partitioning device...")) - // Remove iso so we boot directly from the disk - s.EjectCOSCD() - // Reboot so we boot into the just installed cos - s.Reboot() - // We are on an efi system, should boot from active - By("Checking we booted from Active partition") - ExpectWithOffset(1, s.BootFrom()).To(Equal(sut.Active)) }) }) }) diff --git a/tests/installer/tests_suite_test.go b/tests/installer/tests_suite_test.go index 9db6998e22e..3a9a598f43e 100644 --- a/tests/installer/tests_suite_test.go +++ b/tests/installer/tests_suite_test.go @@ -5,9 +5,17 @@ import ( . "github.com/onsi/ginkgo" . "github.com/onsi/gomega" + "github.com/rancher-sandbox/cOS/tests/sut" ) func TestTests(t *testing.T) { RegisterFailHandler(Fail) RunSpecs(t, "cOS Installer test Suite") } + +func CheckPartitionValues(diskLayout sut.DiskLayout, entry sut.PartitionEntry) { + part, err := diskLayout.GetPartition(entry.Label) + Expect(err).To(BeNil()) + Expect((part.Size / 1024) / 1024).To(Equal(entry.Size)) + Expect(part.FsType).To(Equal(entry.FsType)) +}