Skip to content

Commit 1fe3f05

Browse files
committed
Update CI to reflect reusable workflows
1 parent ae29ea7 commit 1fe3f05

File tree

1 file changed

+39
-6
lines changed

1 file changed

+39
-6
lines changed

.github/workflows/ci.yml

Lines changed: 39 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,10 @@ on:
55
branches:
66
- "main"
77
workflow_dispatch:
8+
9+
env:
10+
PUPPET_FORGE_TOKEN: ${{ secrets.PUPPET_FORGE_TOKEN_PUBLIC }}
11+
BUNDLE_RUBYGEMS___PUPPETCORE__PUPPET__COM: "forge-key:${{ secrets.PUPPET_FORGE_TOKEN_PUBLIC }}"
812

913
jobs:
1014
Spec:
@@ -19,10 +23,13 @@ jobs:
1923
runs-on: "ubuntu-24.04"
2024
outputs:
2125
matrix: ${{ steps.get-matrix.outputs.matrix }}
26+
27+
env:
28+
BUNDLE_WITHOUT: release_prep
2229

2330
steps:
2431
- name: "Checkout"
25-
uses: "actions/checkout@v3"
32+
uses: "actions/checkout@v4"
2633
with:
2734
ref: ${{ github.event.pull_request.head.sha }}
2835

@@ -35,28 +42,49 @@ jobs:
3542
- name: Setup Test Matrix
3643
id: get-matrix
3744
run: |
38-
bundle exec matrix_from_metadata_v2 --provision-service
45+
bundle exec matrix_from_metadata_v3 --provision-prefer provision_service --nightly
3946
4047
Acceptance:
41-
name: "Acceptance tests (${{matrix.platforms.label}}, ${{matrix.collection}})"
48+
name: "Acceptance tests (${{matrix.platforms.label}}, ${{matrix.collection.collection || matrix.collection}})"
4249
needs: setup_matrix
4350
runs-on: ubuntu-latest
51+
timeout-minutes: 180
4452
strategy:
4553
fail-fast: false
4654
matrix: ${{fromJson(needs.setup_matrix.outputs.matrix)}}
4755

4856
env:
49-
PUPPET_GEM_VERSION: '~> 7.24'
57+
BUNDLE_WITHOUT: release_prep
58+
PUPPET_GEM_VERSION: '~> 8.9'
5059
FACTER_GEM_VERSION: 'https://github.com/puppetlabs/facter#main' # why is this set?
60+
TWINGATE_PUBLIC_REPO_KEY: ${{ secrets.TWINGATE_PUBLIC_REPO_KEY }}
5161

5262
steps:
5363
- name: "Install Twingate"
5464
uses: "twingate/github-action@v1"
5565
with:
5666
service-key: ${{ secrets.TWINGATE_PUBLIC_REPO_KEY }}
5767

68+
- name: Fix DNS
69+
run: |
70+
echo "=== Remove Azure DNS from eth0 interface ==="
71+
sudo resolvectl dns eth0 ""
72+
73+
echo "=== Configure Twingate DNS properly ==="
74+
sudo resolvectl dns sdwan0 100.95.0.251 100.95.0.252
75+
sudo resolvectl domain sdwan0 delivery.puppetlabs.net
76+
77+
echo "=== Flush DNS cache ==="
78+
sudo resolvectl flush-caches
79+
80+
echo "=== Check new configuration ==="
81+
resolvectl status
82+
83+
echo "=== Test DNS resolution ==="
84+
nslookup artifactory.delivery.puppetlabs.net
85+
5886
- name: "Checkout"
59-
uses: "actions/checkout@v3"
87+
uses: "actions/checkout@v4"
6088
with:
6189
ref: ${{ github.event.pull_request.head.sha }}
6290

@@ -79,7 +107,12 @@ jobs:
79107
80108
- name: "Install Puppet agent"
81109
run: |
82-
bundle exec rake 'litmus:install_agent[${{ matrix.collection }}]'
110+
if [[ "${{ matrix.collection.version }}" ]] ; then
111+
export PUPPET_VERSION=${{ matrix.collection.version }}
112+
bundle exec rake 'litmus:install_agent[${{ matrix.collection.collection }}]'
113+
else
114+
bundle exec rake 'litmus:install_agent[${{ matrix.collection }}]'
115+
fi
83116
84117
- name: "Install module"
85118
run: |

0 commit comments

Comments
 (0)