feat: Add config example for host extension #3511
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: E2E-Test | |
| on: | |
| pull_request: | |
| branches: [main] | |
| push: | |
| branches: [main] | |
| defaults: | |
| run: | |
| shell: bash | |
| env: | |
| KUBECONFIG: /tmp/kube-config-collector-e2e-testing | |
| # renovate: datasource=golang-version depName=go | |
| GO_VERSION: "1.25.6" | |
| jobs: | |
| docker-build: | |
| runs-on: ubuntu-24.04 | |
| steps: | |
| - name: Check out code | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| - name: Setup Go | |
| uses: actions/setup-go@7a3fe6cf4cb3a834922a1244abfce67bcef6a0c5 # v6.2.0 | |
| with: | |
| go-version: ${{ env.GO_VERSION }} | |
| cache-dependency-path: "**/*.sum" | |
| - name: Install tools | |
| run: | | |
| mkdir -p .tools | |
| make install-tools | |
| - name: Generate source files | |
| run: make generate | |
| - name: Build collector artifact | |
| shell: bash | |
| run: | | |
| echo "Building collector artifact" | |
| make build | |
| - name: Upload binary artifact | |
| uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0 | |
| with: | |
| name: dynatrace-otel-collector-bin | |
| path: bin/dynatrace-otel-collector | |
| - name: Set up QEMU | |
| uses: docker/setup-qemu-action@c7c53464625b32c7a7e944ae62b3e17d2b600130 # v3.7.0 | |
| - name: Set up Docker Buildx | |
| uses: docker/setup-buildx-action@8d2750c68a42422c14e847fe6c8ac0403b4cbd6f # v3.12.0 | |
| - name: Build and push to local registry | |
| uses: docker/build-push-action@263435318d21b8e681c14492fe198d362a7d2c83 # v6.18.0 | |
| with: | |
| context: ./bin | |
| file: Dockerfile | |
| push: false | |
| load: true | |
| tags: dynatrace-otel-collector:e2e-test | |
| - name: export image to tar | |
| run: | | |
| docker save dynatrace-otel-collector:e2e-test > /tmp/dynatrace-otel-collector.tar | |
| - name: Upload container image artifact | |
| uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0 | |
| with: | |
| name: dynatrace-otel-collector-image | |
| path: /tmp/dynatrace-otel-collector.tar | |
| k8s-multinode-matrix: | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| usecase: | |
| - k8scombined | |
| runs-on: ubuntu-24.04 | |
| needs: docker-build | |
| steps: | |
| - name: Check out code | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| - name: Setup cluster | |
| uses: ./.github/actions/create-cluster | |
| with: | |
| config: "./.github/actions/create-cluster/multi-node.yaml" | |
| - name: Run e2e tests | |
| run: | | |
| cd internal/testbed/integration/${{ matrix.usecase }} | |
| go test -v --tags=e2e | |
| k8s-e2e-test-matrix: | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| usecase: | |
| - k8senrichment | |
| - prometheus | |
| - zipkin | |
| - statsd | |
| - redaction | |
| - resource-detection | |
| - netflow | |
| - self-monitoring | |
| - hostmetrics | |
| - k8sobjects | |
| - kubeletstats | |
| - k8scluster | |
| - loadbalancing | |
| - kafka | |
| runs-on: ubuntu-24.04 | |
| needs: docker-build | |
| steps: | |
| - name: Check out code | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| - name: Setup cluster | |
| uses: ./.github/actions/create-cluster | |
| - name: Run e2e tests | |
| run: | | |
| cd internal/testbed/integration/${{ matrix.usecase }} | |
| go test -v --tags=e2e | |
| combined-load-test: | |
| if: github.event_name == 'push' && github.ref == 'refs/heads/main' | |
| runs-on: "Linux-x64-16-64GB-Runner" # Ubuntu 24.04 | |
| needs: docker-build | |
| steps: | |
| - name: Check out code | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| - name: Setup cluster | |
| uses: ./.github/actions/create-cluster | |
| - name: Run e2e tests | |
| run: | | |
| cd internal/testbed/integration/combinedload | |
| go test -v --tags=e2e | |
| helm-install-test: | |
| if: github.event_name == 'push' && github.ref == 'refs/heads/main' | |
| runs-on: ubuntu-24.04 | |
| needs: docker-build | |
| steps: | |
| - name: Check out code | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| - name: Setup cluster | |
| uses: ./.github/actions/create-cluster | |
| - name: Run helm installation | |
| env: | |
| REPOSITORY: "dynatrace-otel-collector" | |
| TAG: "e2e-test" | |
| run: | | |
| ./internal/testbed/scripts/install_dt_collector_helm.sh || exit 1; | |
| eec-confmap-provider: | |
| runs-on: ubuntu-24.04 | |
| needs: docker-build | |
| steps: | |
| - name: Check out code | |
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | |
| - name: Setup Go | |
| uses: actions/setup-go@7a3fe6cf4cb3a834922a1244abfce67bcef6a0c5 # v6.2.0 | |
| with: | |
| go-version: ${{ env.GO_VERSION }} | |
| check-latest: true | |
| cache-dependency-path: "**/*.sum" | |
| - name: Download artifact | |
| uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v7.0.0 | |
| with: | |
| name: dynatrace-otel-collector-bin | |
| path: bin | |
| - run: chmod +x bin/* | |
| - name: Run e2e tests | |
| run: | | |
| cd internal/confmap/provider/eecprovider | |
| go test -v --tags=e2e | |
| notify-slack-combined-load-test: | |
| runs-on: ubuntu-24.04 | |
| needs: [combined-load-test] | |
| if: failure() && github.event_name == 'push' | |
| steps: | |
| - name: Slack Notification | |
| uses: rtCamp/action-slack-notify@e31e87e03dd19038e411e38ae27cbad084a90661 # v2.3.3 | |
| env: | |
| SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} | |
| SLACK_TITLE: "DT OTel Collector Distro - Combined Load Test Failure" | |
| SLACK_COLOR: "failure" | |
| SLACK_USERNAME: "GitHub Actions Notifier" | |
| SLACK_ICON: "https://cdn.jsdelivr.net/gh/walkxcode/dashboard-icons/png/github.png" | |
| notify-slack-e2e-tests: | |
| runs-on: ubuntu-24.04 | |
| needs: [k8s-e2e-test-matrix, eec-confmap-provider, k8s-multinode-matrix] | |
| if: failure() && github.event_name == 'push' | |
| steps: | |
| - name: Slack Notification | |
| uses: rtCamp/action-slack-notify@e31e87e03dd19038e411e38ae27cbad084a90661 # v2.3.3 | |
| env: | |
| SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} | |
| SLACK_TITLE: "DT OTel Collector Distro - E2E Test Failure" | |
| SLACK_COLOR: "failure" | |
| SLACK_USERNAME: "GitHub Actions Notifier" | |
| SLACK_ICON: "https://cdn.jsdelivr.net/gh/walkxcode/dashboard-icons/png/github.png" |