Hello, quick question from newbie about projects a...
# general
c
Hello, quick question from newbie about projects and stacks naming. I have following folder structure (currently trying to migrate off terraform) that is kept in GIT.
Copy code
└── infrastructure
    └── network
        ├── dev
        ├── prod
        └── stage
            ├── 01-host-project
            │   ├── Pulumi.stage.yaml
            │   └── Pulumi.yaml
            └── 02-host-vpc
                ├── Pulumi.stage.yaml
                └── Pulumi.yaml
So by default I am getting:
<organisation>/02-host-vpc/stage
as a stack name. What is the suggested approach to have project name aligned to my directory structure? Ideally something like:
<organisation>/infrastructure/network/02-host-vpc/stage
? Also I use this directory structure as a template for different projects/customers does it mean that for each separate deployment I need to have different
<organisation>
? Thanks!!😉
f
There are a number of ways to structure this. Stacks and projects are purposely flexible in this way. Based on the way you’re talking about it, if the idea is that each customer is using the same template, you could have a stack per customer. Then, as you update your Pulumi program (on a per-stage basis), you could update each customer’s stack based on that template.
In the
<org>/<project>/<stack>
naming scheme, the
org
refers to the Pulumi organization that owns that stack. So your company for example or yourself as an individual.
c
Thanks. So to understand it better how do you suggest naming my stack so it reflects provided directory structure?
f
If you haven’t already, I’d suggest reading https://www.pulumi.com/docs/intro/concepts/organizing-stacks-projects/ which gives some ideas