From 52ffe58df85560560d8e1971ea45fff14fdfcdfe Mon Sep 17 00:00:00 2001 From: Imran Iqbal Date: Sat, 18 Dec 2021 19:22:42 +0000 Subject: [PATCH] ci(proxy): replace deprecated `windows-2016` with `windows-2022` * https://github.com/actions/virtual-environments/issues/4312 --- .github/workflows/kitchen.windows.yml | 110 +++++++++++++------------- kitchen.windows.yml | 2 +- 2 files changed, 56 insertions(+), 56 deletions(-) diff --git a/.github/workflows/kitchen.windows.yml b/.github/workflows/kitchen.windows.yml index 0b2d2c1..214173e 100644 --- a/.github/workflows/kitchen.windows.yml +++ b/.github/workflows/kitchen.windows.yml @@ -36,6 +36,61 @@ jobs: - name: 'ShellCheck' run: | shellcheck -s sh -f tty bootstrap-salt.sh + test-2022: + runs-on: 'windows-2022' + timeout-minutes: 20 + needs: 'lint' + strategy: + fail-fast: false + matrix: + instance: + - py3-stable-3001-windows-2022 + - py3-stable-3002-windows-2022 + - py3-stable-3003-windows-2022 + - latest-windows-2022 + steps: + - name: 'Check out code' + uses: 'actions/checkout@v2' + - name: 'Install Chef' + uses: 'actionshub/chef-install@1.1.0' + with: + project: 'chef' + version: '16.10.8' + - name: 'Add Chef bindir to PATH' + uses: 'myci-actions/export-env-var-powershell@1' + with: + name: 'PATH' + value: "C:\\opscode\\chef\\bin;\ + C:\\opscode\\chef\\embedded\\bin;$env:PATH" + - name: 'Set up Bundler cache' + uses: 'actions/cache@v1' + with: + path: 'vendor/bundle' + key: "${{ runner.os }}-gems-${{ hashFiles('**/Gemfile.lock') }}" + restore-keys: "${{ runner.os }}-gems-" + - name: 'Set up test user' + run: | + $password = ConvertTo-SecureString $env:machine_pass -AsPlainText -Force + New-LocalUser $env:machine_user -Password $password + Add-LocalGroupMember -Group "Administrators" -Member $env:machine_user + - name: 'Set up WinRM' + run: | + Set-WSManQuickConfig -Force + - name: 'Run Bundler' + run: | + ruby --version + bundle config path vendor/bundle + bundle install --jobs 4 --retry 3 + - name: 'Set up Python 3.7' + uses: 'actions/setup-python@v1' + with: + python-version: '3.7' + - name: 'Install Python Dependencies' + run: | + pip install -U pip + pip install -r tests/requirements.txt + - name: 'Run Test Kitchen' + run: 'bundle exec kitchen test ${{ matrix.instance }}' test-2019: runs-on: 'windows-2019' timeout-minutes: 20 @@ -91,58 +146,3 @@ jobs: pip install -r tests/requirements.txt - name: 'Run Test Kitchen' run: 'bundle exec kitchen test ${{ matrix.instance }}' - test-2016: - runs-on: 'windows-2016' - timeout-minutes: 20 - needs: 'lint' - strategy: - fail-fast: false - matrix: - instance: - - py3-stable-3001-windows-2016 - - py3-stable-3002-windows-2016 - - py3-stable-3003-windows-2016 - - latest-windows-2016 - steps: - - name: 'Check out code' - uses: 'actions/checkout@v2' - - name: 'Install Chef' - uses: 'actionshub/chef-install@1.1.0' - with: - project: 'chef' - version: '16.10.8' - - name: 'Add Chef bindir to PATH' - uses: 'myci-actions/export-env-var-powershell@1' - with: - name: 'PATH' - value: "C:\\opscode\\chef\\bin;\ - C:\\opscode\\chef\\embedded\\bin;$env:PATH" - - name: 'Set up Bundler cache' - uses: 'actions/cache@v1' - with: - path: 'vendor/bundle' - key: "${{ runner.os }}-gems-${{ hashFiles('**/Gemfile.lock') }}" - restore-keys: "${{ runner.os }}-gems-" - - name: 'Set up test user' - run: | - $password = ConvertTo-SecureString $env:machine_pass -AsPlainText -Force - New-LocalUser $env:machine_user -Password $password - Add-LocalGroupMember -Group "Administrators" -Member $env:machine_user - - name: 'Set up WinRM' - run: | - Set-WSManQuickConfig -Force - - name: 'Run Bundler' - run: | - ruby --version - bundle config path vendor/bundle - bundle install --jobs 4 --retry 3 - - name: 'Set up Python 3.7' - uses: 'actions/setup-python@v1' - with: - python-version: '3.7' - - name: 'Install Python Dependencies' - run: | - pip install -U pip - pip install -r tests/requirements.txt - - name: 'Run Test Kitchen' - run: 'bundle exec kitchen test ${{ matrix.instance }}' diff --git a/kitchen.windows.yml b/kitchen.windows.yml index 109f97e..1ed2446 100644 --- a/kitchen.windows.yml +++ b/kitchen.windows.yml @@ -13,8 +13,8 @@ provisioner: init_environment: '' platforms: + - name: windows-2022 - name: windows-2019 - - name: windows-2016 suites: - name: py3-stable-3001