Skip to content

Conversation

@mcoulombe
Copy link
Contributor

What this PR does / why we need it:

Allows the Tailscale Terraform provider to dynamically generate an API access token by exchanging an identity token. This way providers do not need to be configured with sensitive information like an authkey or oauth_client_secret.

Configuring a federated identity OAuth client is private at the time of this PR but public access is coming soon™️.

Updates #485

Special notes for your reviewer:

Depends on this PR on the client. I'll update the dependency with the proper stable release before merging.

Copy link
Collaborator

@oxtoacart oxtoacart left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Generally LGTM, just a couple of nits.

Description: "The API key to use for authenticating requests to the API. Can be set via the TAILSCALE_API_KEY environment variable. Conflicts with 'oauth_client_id' and 'oauth_client_secret'.",
Sensitive: true,
},
"identity_token": {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you want to name this and the environment variable something that makes it clear it's for workload identity federation?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't have a strong preference, do you mean wif_identity_token? @mpminardi any thoughts on the naming?

Copy link
Contributor Author

@mcoulombe mcoulombe Oct 17, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Follow-up from a Slack conversation, Sam felt against the wif prefix and we'll support both TAILSCALE_IDENTITY_TOKEN and IDENTITY_TOKEN env vars to be consistent with the OAuth fields.

@mcoulombe mcoulombe force-pushed the max/identity-federation-support branch 3 times, most recently from 6313cb2 to c891e9f Compare October 17, 2025 18:22
@mcoulombe mcoulombe force-pushed the max/identity-federation-support branch from c891e9f to 2133416 Compare October 17, 2025 18:25
Copy link
Collaborator

@oxtoacart oxtoacart left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Still LGTM.

@mcoulombe mcoulombe merged commit 6da8cb4 into main Oct 17, 2025
5 checks passed
@mcoulombe mcoulombe deleted the max/identity-federation-support branch October 17, 2025 22:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants