Helm chart: add support for export.stdout.envFromSecrets to inject environment variables from Kubernetes secrets #12849
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Tetragon e2e Test | |
on: | |
pull_request: | |
paths-ignore: | |
- 'docs/**' | |
push: | |
branches: | |
- main | |
paths-ignore: | |
- 'docs/**' | |
concurrency: | |
group: ${{ github.ref }} | |
cancel-in-progress: true | |
env: | |
clusterName: tetragon-ci | |
jobs: | |
prepare: | |
runs-on: ubuntu-24.04 | |
outputs: | |
packages: ${{ steps.set-packages.outputs.packages }} | |
agentImage: ${{ steps.vars.outputs.agentImage }} | |
operatorImage: ${{ steps.vars.outputs.operatorImage }} | |
steps: | |
- name: Checkout Code | |
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0 | |
- name: Install Go | |
uses: actions/setup-go@d35c59abb061a4a6fb18e82ac0862c26744d6ab5 # v5.5.0 | |
with: | |
go-version-file: go.mod | |
- id: set-packages | |
name: Listing e2e tests packages | |
shell: bash | |
run: | | |
echo PACKAGES=$(make ls-e2e-test | jq -Rnc '[inputs | {"s": split("/")[-1], "f":.}]') | tee -a $GITHUB_STEP_SUMMARY | tee -a $GITHUB_OUTPUT | |
- name: Set Up Job Variables | |
id: vars | |
run: | | |
if [ ${{ github.event.issue.pull_request || github.event.pull_request }} ]; then | |
PR_API_JSON=$(curl \ | |
-H "Accept: application/vnd.github.v3+json" \ | |
-H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" \ | |
${{ github.event.issue.pull_request.url || github.event.pull_request.url }}) | |
SHA=$(echo "$PR_API_JSON" | jq -r ".head.sha") | |
else | |
SHA=${{ github.sha }} | |
fi | |
echo "agentImage=quay.io/cilium/tetragon-ci:${SHA}" >> $GITHUB_OUTPUT | |
echo "operatorImage=quay.io/cilium/tetragon-operator-ci:${SHA}" >> $GITHUB_OUTPUT | |
- name: Wait Tetragon Images | |
uses: nick-fields/retry@ce71cc2ab81d554ebbe88c79ab5975992d79ba08 # v3.0.2 | |
with: | |
timeout_minutes: 2 | |
max_attempts: 30 | |
retry_wait_seconds: 30 | |
warning_on_retry: false | |
command: | | |
set -e | |
docker pull ${{ steps.vars.outputs.agentImage }} | |
docker pull ${{ steps.vars.outputs.operatorImage }} | |
docker rmi ${{ steps.vars.outputs.agentImage }} ${{ steps.vars.outputs.operatorImage }} | |
run-e2e-test: | |
needs: prepare | |
runs-on: ${{ matrix.os }} | |
timeout-minutes: 20 | |
name: ${{matrix.os}} / ${{ matrix.package.s }} | |
strategy: | |
fail-fast: false | |
matrix: | |
os: [ ubuntu-22.04, ubuntu-22.04-arm64 ] | |
package: ${{fromJson(needs.prepare.outputs.packages)}} | |
steps: | |
- name: Checkout Code | |
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0 | |
with: | |
path: go/src/github.com/cilium/tetragon/ | |
- name: Install Go | |
uses: actions/setup-go@d35c59abb061a4a6fb18e82ac0862c26744d6ab5 # v5.5.0 | |
with: | |
# renovate: datasource=golang-version depName=go | |
go-version: '1.25.1' | |
- name: Install kubectl | |
uses: azure/setup-kubectl@776406bce94f63e41d621b960d78ee25c8b76ede # v4.0.1 | |
with: | |
# renovate: datasource=github-releases depName=kubernetes/kubernetes | |
version: v1.34.1 | |
- name: Install Helm | |
uses: azure/setup-helm@1a275c3b69536ee54be43f2070a358922e12c8d4 # v4.3.1 | |
with: | |
# renovate: datasource=github-releases depName=helm/helm | |
version: v3.19.0 | |
- name: Install Kind | |
uses: helm/kind-action@a1b0e391336a6ee6713a0583f8c6240d70863de3 # v1.12.0 | |
with: | |
install_only: true | |
# renovate: datasource=github-releases depName=kubernetes-sigs/kind | |
version: v0.30.0 | |
- name: Pull Tetragon Images | |
uses: nick-fields/retry@ce71cc2ab81d554ebbe88c79ab5975992d79ba08 # v3.0.2 | |
with: | |
timeout_minutes: 2 | |
max_attempts: 30 | |
retry_wait_seconds: 30 | |
warning_on_retry: false | |
command: | | |
set -e | |
docker pull ${{ needs.prepare.outputs.agentImage }} | |
docker pull ${{ needs.prepare.outputs.operatorImage }} | |
- name: Run e2e Tests | |
run: | | |
cd go/src/github.com/cilium/tetragon | |
make e2e-test E2E_TESTS=${{matrix.package.f}} E2E_BUILD_IMAGES=0 E2E_AGENT=${{ needs.prepare.outputs.agentImage }} E2E_OPERATOR=${{ needs.prepare.outputs.operatorImage }} EXTRA_TESTFLAGS="-cluster-name=${{ env.clusterName }} -args -v=4" | |
- name: Upload Tetragon Logs | |
if: failure() || cancelled() | |
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2 | |
with: | |
name: tetragon-logs-${{ matrix.os }}-${{ matrix.package.s }} | |
path: /tmp/tetragon.e2e.* | |
retention-days: 5 |