https://pulumi.com logo
#general
Title
# general
a

able-camera-57198

11/10/2021, 4:56 PM
Is it possible to initialize a stack without creating a
.yaml
file in the current folder? (I plan on using
--config-file
)
m

millions-furniture-75402

11/10/2021, 5:56 PM
I don't believe so because of the tight coupling with the
pulumi config
command, even in the automation API. https://github.com/pulumi/pulumi/blob/master/sdk/nodejs/automation/localWorkspace.ts#L416
which has that annoying side effect of removing your YAML file when you
pulumi stack rm
a

able-camera-57198

11/10/2021, 6:01 PM
Yeah, I kind of wish stacks were more internal than the
.yaml
that ends up functioning as config.
There's a design choice somewhere inside of how stacks and stack configs work that make them difficult to reuse between projects.
I don't know if this is the right way to put it, but it's almost like I wish "stack state supported multiple projects".
m

millions-furniture-75402

11/10/2021, 6:07 PM
Yes, I ran into this issue when trying to abuse Config for my own needs, not a stack. I had manage my own YAML separately 😞 (first world cloud development problems)
a

able-camera-57198

11/10/2021, 6:38 PM
Yeah, and now I find myself writing shell scripts to manage this away as I don't want to be managing multiple files all with the same base settings.
I think I've got a strategy for it, but it's just obviously weird.
The symlinking to the
.yaml
file helps me keep just one config file with config for all my projects in it.