Skip to content

Conversation

@seanyeh
Copy link
Contributor

@seanyeh seanyeh commented Sep 19, 2025

We're not setting the audience correctly if escEnvOrg is set in config. they need to always match

@seanyeh seanyeh requested a review from a team September 19, 2025 16:40
@seanyeh seanyeh marked this pull request as ready for review September 19, 2025 16:41
@seanyeh seanyeh requested a review from jkodroff as a code owner September 19, 2025 16:41
Copy link
Member

@jkodroff jkodroff left a comment

Choose a reason for hiding this comment

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

Nice catch.

@nyobe
Copy link

nyobe commented Sep 19, 2025

for my own education, in what cases would someone want to set escEnvOrg? won't ESC always set the audience to the pulumi org the esc environment resides in?

edit: ohh, escEnvOrg drives which org the environment is actually deployed into, derp.

@seanyeh
Copy link
Contributor Author

seanyeh commented Sep 19, 2025

@nyobe someone can set it if they want to create an environment in a specific org. but we're always setting audience to the default org (which could be different). this fix makes it so that it uses the same org for both

@seanyeh seanyeh enabled auto-merge September 19, 2025 16:47

const oidcProvider = new gcp.iam.WorkloadIdentityPoolProvider(`identity-pool-provider`, {
workloadIdentityPoolId: identityPool.workloadIdentityPoolId,
workloadIdentityPoolProviderId: `pulumi-cloud-${pulumi.getOrganization()}-oidc`,
Copy link
Member

Choose a reason for hiding this comment

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

Should this also be escEnvOrg?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

yup, nice catch

@seanyeh seanyeh merged commit 82681f2 into master Sep 20, 2025
78 of 80 checks passed
@seanyeh seanyeh deleted the syeh/fix-audience-gcp-oidc branch September 20, 2025 02:04
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.

6 participants