@@ -266,7 +266,101 @@ jobs:
266266 name : official-oss-integration-test-logs-${{ matrix.container.image }}-${{ matrix.container.version }}
267267 path : /tmp/integration-test-logs/
268268 retention-days : 3
269+ official-plus-image-integration-tests :
270+ name : Integration Tests - Official Plus Images
271+ needs : build-unsigned-snapshot
272+ runs-on : ubuntu-24.04
273+ permissions :
274+ id-token : write # for OIDC authentication
275+ if : ${{ !github.event.pull_request.head.repo.fork && !startsWith(github.ref_name, 'dependabot/') }}
276+ strategy :
277+ fail-fast : false
278+ matrix :
279+ container :
280+ - image : " alpine"
281+ version : " 3.20"
282+ plus : " r32"
283+ release : " alpine"
284+ path : " /nginx-plus/agent"
285+ - image : " debian"
286+ version : " bookworm"
287+ plus : " r32"
288+ release : " debian"
289+ path : " /nginx-plus/agent"
290+ - image : " debian"
291+ version : " bookworm"
292+ plus : " r31"
293+ release : " debian"
294+ path : " /nginx-plus/agent"
295+ steps :
296+ - uses : actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
297+ with :
298+ fetch-depth : 0
299+ - uses : actions/setup-go@7a3fe6cf4cb3a834922a1244abfce67bcef6a0c5 # v6.2.0
300+ with :
301+ go-version-file : ' go.mod'
302+ - name : Download Packages
303+ uses : actions/download-artifact@65a9edc5881444af0b9093a5e628f2fe47ea3b2e # v4.1.7
304+ with :
305+ name : nginx-agent-unsigned-snapshots
306+ path : build
307+
308+ - name : Get Secrets from Agent Key Vault
309+ uses : ./.github/actions/az-sync
310+ with :
311+ az_client_id : ${{ secrets.AZ_KEYVAULT_CLIENT_ID }}
312+ az_tenant_id : ${{ secrets.AZ_KEYVAULT_TENANT_ID }}
313+ az_subscription_id : ${{ secrets.AZ_SUBSCRIPTION_ID }}
314+ keyvault : ${{ secrets.AZ_KEYVAULT_AGENT }}
315+ secrets-filter : ' artifactory'
316+
317+ - name : Sync Secrets from Common Key Vault
318+ uses : ./.github/actions/az-sync
319+ with :
320+ az_client_id : ${{ secrets.AZ_KEYVAULT_CLIENT_ID }}
321+ az_tenant_id : ${{ secrets.AZ_KEYVAULT_TENANT_ID }}
322+ az_subscription_id : ${{ secrets.AZ_SUBSCRIPTION_ID }}
323+ keyvault : ${{ secrets.AZ_KEYVAULT_COMMON }}
324+ secrets-filter : ' docker,nginx-private-registry,nginx-pkg'
325+
326+ - name : Login to Docker Registry
327+ uses : docker/login-action@5e57cd118135c172c3672efd75eb46360885c0ef # v3.6.0
328+ with :
329+ registry : ${{ env.nginx-private-registry-url }}
330+ username : ${{ env.nginx-pkg-jwt }}
331+ password : " none"
332+
333+ - name : Set Start Time
334+ run : echo "START_TIME=$(date +"%Y-%m-%dT%H:%M:%S.%NZ")" >> ${GITHUB_ENV}
335+ - name : Create Directory
336+ run : mkdir -p ${{github.workspace}}/test/dashboard/logs/${{github.job}}/${{matrix.container.image}}${{matrix.container.version}}/
337+ - name : Start Promtail
338+ uses : ./.github/actions/start-promtail
339+ with :
340+ loki-dashboard-url : ${{ secrets.LOKI_DASHBOARD_URL }}
341+ - name : Run Integration Tests
342+ run : |
343+ go install github.com/goreleaser/nfpm/v2/cmd/nfpm@${{ env.NFPM_VERSION }}
344+ CONTAINER_NGINX_IMAGE_REGISTRY="${{ env.nginx-private-registry-url }}" TAG="${{ matrix.container.plus }}-${{ matrix.container.image }}-${{ matrix.container.version }}" \
345+ OS_RELEASE="${{ matrix.container.release }}" IMAGE_PATH="${{ matrix.container.path }}" \
346+ make official-image-integration-test | tee ${{github.workspace}}/test/dashboard/logs/${{github.job}}/${{matrix.container.image}}${{matrix.container.version}}/raw_logs.log && exit "${PIPESTATUS[0]}"
347+ - name : Generate Test Results
348+ if : always()
349+ run : bash ./scripts/workflow/generate_results.sh ${{job.status}} ${{env.START_TIME}} ${{github.job}}/${{matrix.container.image}}${{matrix.container.version}} ${{github.workspace}}
350+ - name : Container Output Logs
351+ if : failure()
352+ run : |
353+ docker ps -a
354+ dockerid=$(docker ps -a --format "{{.ID}}")
355+ docker logs "$dockerid"
269356
357+ - name : Archive integration test logs
358+ if : success() || failure()
359+ uses : actions/upload-artifact@65462800fd760344b1a7b4382951275a0abb4808 # v4.3.3
360+ with :
361+ name : official-plus-integration-test-logs-${{ matrix.container.image }}-${{ matrix.container.version }}-${{ matrix.container.plus }}
362+ path : /tmp/integration-test-logs/
363+ retention-days : 3
270364 performance-test :
271365 name : Performance Tests
272366 if : ${{ !github.event.pull_request.head.repo.fork && !startsWith(github.ref_name, 'dependabot/') }}
0 commit comments