Guidance for working with Pulumi ESC (Environments, Secrets, and Configuration). Use when users ask about managing secrets, configuration, environments, short-term credentials, configuring OIDC for AWS, Azure, GCP, integrating with secret stores (AWS Secrets Manager, Azure Key Vault, HashiCorp Vault, 1Password), or using ESC with Pulumi stacks.
90
Does it follow best practices?
If you maintain this skill, you can automatically optimize it using the tessl CLI to improve its score:
npx tessl skill review --optimize ./path/to/skillValidation for skill structure
Pulumi ESC is a centralized service for managing environments, secrets, and configuration across cloud infrastructure and applications.
ESC enables teams to:
# Create a new environment
pulumi env init <org>/<project-name>/<environment-name>
# Edit environment (opens in editor)
pulumi env edit <org>/<project-name>/<environment-name>
# Set values
pulumi env set <org>/<project-name>/<environment-name> <key> <value>
pulumi env set <org>/<project-name>/<environment-name> <key> <value> --secret
# View definition (secrets hidden)
pulumi env get <org>/<project-name>/<environment-name>
# Open and resolve (reveals secrets)
pulumi env open <org>/<project-name>/<environment-name>
# Run command with environment
pulumi env run <org>/<project-name>/<environment-name> -- <command>
# Link to Pulumi stack
pulumi config env add <project-name>/<environment-name>pulumi env get: Shows static definition, secrets appear as [secret]pulumi env open: Resolves and reveals all values including secrets and dynamic credentialspulumi env run: Executes commands with environment variables loadedpulumi config env add: Only takes the <project-name>/<environment-name> portionEnvironments are YAML documents with reserved top-level keys:
imports: Import and compose other environmentsvalues: Define configuration and secretsReserved sub-keys under values:
environmentVariables: Map values to shell environment variablespulumiConfig: Configure Pulumi stack settingsfiles: Generate files with environment dataimports:
- common/base-config
values:
environment: production
region: us-west-2
dbPassword:
fn::secret: super-secure-password
environmentVariables:
AWS_REGION: ${region}
DB_PASSWORD: ${dbPassword}
pulumiConfig:
aws:region: ${region}
app:dbPassword: ${dbPassword}If the user asks basic questions like "How do I create an environment?" or "What's the difference between get and open?", answer directly using the information above.
When users need more information, use the web-fetch tool to get content from the official Pulumi ESC documentation:
pulumi env subcommands over esc CLI.Use the web-fetch tool with specific prompts to extract relevant information from these docs.
When helping users:
pulumi env commands to list environments or read definitionspulumi env get or pulumi preview
a. Only use pulumi env open when the full resolved values are needed, but use cautiously as it reveals secrets.User: "How do I set up AWS OIDC credentials in ESC?"
1. Use the web-fetch tool to get AWS OIDC documentation from "https://www.pulumi.com/docs/esc/integrations/dynamic-login-credentials/aws-login/"
2. Provide the user with the configuration
3. Ask the user if they have a pre-defined role or need one created for them
4. Set up as much of the environment as possible, then guide them through any steps that you can't do for them
5. Help them test with `pulumi env get` or `pulumi env open` if necessarypulumi env init my-org/my-project/dev-config
# Edit environment (accepts new definition from a file, better for agents, more difficult for users)
pulumi env edit --file /tmp/example.yml my-org/my-project/dev-configpulumi config env add my-project/dev-config
pulumi config # Verify environment values are accessibleAlways prefer CLI commands. Only use the API when absolutely necessary (e.g., bulk operations, automation).
Available API endpoints include:
GET /api/esc/environments/{orgName} - List environmentsGET /api/esc/environments/{orgName}/{projectName}/{envName} - Read environment definitionGET /api/esc/providers?orgName={orgName} - List available providersUse call_pulumi_cloud_api() tool to make requests when needed.
fn::secret for sensitive values<org>/my-app/production-aws not <org>/app/prodpulumi config shows expected values after linking an environment to a stackpulumi env run for commands needing environment variablespulumi env open when absolutely necessary, as it reveals secretspulumi env ls -o <org>pulumi env open not pulumi env getpulumi config env ls to ensure the stack is listed.
pulumi env get <org>/<project-name>/<environment-name>.pulumiConfig key exists and is nested under the values key.b6b942f
If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.