straight-fireman-55591
08/02/2024, 12:55 PMinfra/
├── Pulumi.yaml
├── Pulumi.product1-rnd.yaml
├── Pulumi.product1-dev.yaml
├── Pulumi.product1-stg.yaml
├── Pulumi.product1-prod.yaml
├── Pulumi.product2-rnd.yaml
├── Pulumi.product2-dev.yaml
├── Pulumi.product2-stg.yaml
├── Pulumi.product2-prod.yaml
Pulumi.yaml
name: my-gcp-infra
runtime: yaml
description: Infrastructure as Code with Pulumi for GCP
Then each file Pulumi.productX-XXX.yaml will have the actual resources to deploy.
Where rnd, dev, stg, prod are different gcp projects for each product for example gcp projects names:
product1-rnd
product1-dev
product1-stg
product1-prod
product2-rnd
.
.
.straight-fireman-55591
08/02/2024, 2:05 PMzephyr/dev how Pulumi knows to deploy to zephyrdev gcp project and when I do pulumi stack select zephyr/prod how does it know to deploy to sephyrprod gcp project ?
This is confusing, because as I understand there is a single pulumi.yaml containing all of resources.
cd infra
pulumi stack select zephyr/dev
pulumi upstraight-fireman-55591
08/02/2024, 2:38 PMpulumi stack select zephyr/dev, Pulumi uses Pulumi.zephyr-dev.yaml for the configuration.
• When you run pulumi stack select zephyr/prod, Pulumi uses Pulumi.zephyr-prod.yaml for the configuration.
• main.yaml is used to keep all the resources and is specified in Pulumi.yaml as?
name: my-project
runtime: yaml
description: My Pulumi Project
main: main.yamlrapid-belgium-27383
08/02/2024, 5:01 PMstraight-fireman-55591
08/05/2024, 8:27 AMstraight-fireman-55591
08/05/2024, 8:27 AMstraight-fireman-55591
08/06/2024, 7:53 AMmodern-zebra-45309
08/06/2024, 8:48 AM