Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,19 +41,22 @@ jobs:
cache: true

- name: Get Datadog credentials
if: github.ref == 'refs/heads/main'
id: dd-sts # Needed to be able to reference this step's output later
uses: DataDog/dd-sts-action@main # Pin to the main branch to get auto updates for free, or to a specific commit hash if you want stability
with:
policy: public-datadog-pup-sts

- name: Configure Datadog Test Optimization
if: github.ref == 'refs/heads/main'
uses: datadog/test-visibility-github-action@v2
with:
languages: go
api_key: ${{ steps.dd-sts.outputs.api_key }}
site: datadoghq.com

- name: Install Datadog CI tools
if: github.ref == 'refs/heads/main'
run: |
# Install orchestrion for Go test instrumentation
go install github.com/DataDog/orchestrion@latest
Expand Down Expand Up @@ -117,7 +120,7 @@ jobs:
go tool cover -func=coverage.out | tail -1 >> coverage_report.txt

- name: Upload coverage to Datadog
if: env.DD_API_KEY != ''
if: github.ref == 'refs/heads/main'
env:
DATADOG_API_KEY: ${{ steps.dd-sts.outputs.api_key }}
DD_SITE: datadoghq.com
Expand Down