Skip to content

Migrate Test Optimization credentials from dd-sts to Datadog WIF - #8621

Merged
cbeauchesne merged 2 commits into
mainfrom
dd/migrate-system-tests-dd-sts-to-wif
Nov 23, 2026
Merged

cbeauchesne merged 2 commits into
mainfrom
dd/migrate-system-tests-dd-sts-to-wif

Conversation

@cbeauchesne

@cbeauchesne cbeauchesne commented Nov 20, 2026 •

Copy link
Copy Markdown
Collaborator

Motivation

SDLC Security is deprecating dd-sts for GitHub workflows in favor of Datadog Workload Identity Federation (WIF). This PR moves the system-tests dd-sts policy (API key only) to the WIF intake mapping, which is already defined in ddoghq/terraform-config#62345.

Every official system-tests job uses this credential, in every repo that calls the reusable workflow. It is needed to tag jobs with ci.framework.name:system-tests and to push JUnit results to Test Optimization. A single commit runs 2000+ of these jobs, so the credential exchange has to be reliable.

Changes

  • .github/actions/datadog_ci/action.yml: replaces DataDog/dd-sts-action (policy system-tests) with DataDog/datadog-workload-identity-federation-github-action/intake, pinned to v1.1.0 (c99aa70b13689969f606ae732c7f9eaaeb44cd70).
    • org_uuid is hardcoded. The org UUID isn't sensitive, and this composite action runs in caller repos (dd-trace-*), where this repo's secrets and variables aren't available.
    • site comes from the existing datadog_site input.
    • exchange_retries: 5 replaces the dd-sts retries: 16. v1.1.0 only retries on 429, 5xx and network errors, with exponential backoff (1s, 2s, 4s, 8s, 16s), so it adds at most about 31s, and only when an exchange fails. A repo missing from the mapping (4xx) fails immediately.
    • The step id is renamed dd-sts to dd-wif. The upload and tag steps now read steps.dd-wif.outputs.api_key. Both stay best effort (continue-on-error).
  • .github/workflows/system-tests.yml: the dd_sts_policy input was already unused. It is now labeled deprecated rather than removed, so callers that still pass it don't break. The id-token: write comment is updated.
  • docs/CI/github-actions.md: replaces the dd-sts mentions with WIF. The note about allowing a caller repo now points to the intake mappings. It also says this is needed for job tagging, not only for Test Optimization (the old note wrongly referred to test_optimization_datadog_site).

Out of scope: GitLab CI still uses the system-tests-gitlab dd-sts policy, because WIF only supports GitHub.

Validation:

  • On this PR's first CI run (v1.0.0, no retries), all 357 jobs that call the action got the ci.framework.name:system-tests tag. All 171 end-to-end jobs uploaded their JUnit results to Test Optimization (171 sessions, about 71,600 tests).
  • yamllint passes on the changed workflow and action files.
  • ./format.sh passes up to its yamlfmt step. That step couldn't download yamlfmt in the sandbox, but it only formats manifests/, which this PR doesn't touch.
  • Caller repos that run the action from GitHub: dd-trace-java, -js, -py, -go, -rb, -rs, -cpp, nginx-datadog, httpd-datadog, datadog-lambda-python, system-tests-dashboard. They need no change: they already grant id-token: write, and need no secret or variable.

Workflow

  1. ⚠️ Create your PR as draft ⚠️
  2. Work on you PR until the CI passes
  3. Mark it as ready for review
    • Tests, manifest, weblog are modified -> you'll need a review from system-tests-reviewers: ask to one of youre co-worker familiar with the tested feature.
    • Framework is modified, or non obvious usage of it -> get a review from system-tests-core (slack)

🚀 Once your PR is reviewed and the CI green, you can merge it!

🛟 #apm-shared-testing 🛟

🤖 Generated with Claude Code (https://claude.com/claude-code)


PR by Bits - View session in Datadog • Open in Slack

Comment @DataDog to request changes

Replace DataDog/dd-sts-action (policy system-tests) with the
datadog-workload-identity-federation-github-action intake action, and
update docs and comments that referenced dd-sts.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Co-authored-by: cbeauchesne <11915659+cbeauchesne@users.noreply.github.com>
@datadog-prod-us1-6

datadog-prod-us1-6 Bot commented Nov 20, 2026 •

Copy link
Copy Markdown

View session in Datadog

Bits Code status: ✅ Done

Comment @DataDog to request changes

@github-actions

Copy link
Copy Markdown
Contributor

CODEOWNERS have been resolved as:

.github/actions/datadog_ci/action.yml                                   @DataDog/system-tests-core
.github/workflows/system-tests.yml                                      @DataDog/system-tests-core
docs/CI/github-actions.md                                               @DataDog/system-tests-core

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Co-authored-by: cbeauchesne <11915659+cbeauchesne@users.noreply.github.com>
@cbeauchesne
cbeauchesne marked this pull request as ready for review November 23, 2026 15:22
@cbeauchesne
cbeauchesne requested a review from a team as a code owner November 23, 2026 15:22
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 23, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-23T15:24:43.522780Z 50713b4 Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@cbeauchesne
cbeauchesne merged commit f6a0417 into main Nov 23, 2026
471 checks passed
@cbeauchesne
cbeauchesne deleted the dd/migrate-system-tests-dd-sts-to-wif branch November 23, 2026 15:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants