sparse-intern-71089
01/15/2021, 8:37 PMmicroscopic-pilot-97530
-g (short for --generate-only) to pulumi new to generate the project only. With that flag, it won’t create a stack, save config, or install dependencies.
Alternatively, you can let pulumi new create the virtual environment, but then after it runs, delete the venv directory and modify the Pulumi.yaml file changing:
runtime:
name: python
options:
virtualenv: venv
To be just:
runtime: pythonmicroscopic-pilot-97530
future-hydrogen-91224
01/16/2021, 6:28 PMmicroscopic-pilot-97530
What do you mean by ‘create a stack’
pulumi new generates a project. By default, pulumi new also creates a new stack (internally running the equivalent of pulumi stack init). You can read more about the difference between a project and stack at https://www.pulumi.com/docs/intro/concepts/programming-model/#program-structure
When -g is specified to pulumi new it won’t create the stack, so it’d be up to you to run pulumi stack init afterwards to create one.wide-journalist-154
03/05/2021, 2:23 PMpulumi new to not create a virtual environment, but do everything else like it did before?