@@ -41,28 +41,30 @@ and referenced from the `site` and `production` environments, e.g.:
4141- OpenTofu configurations should be defined in the `site` environment and used
4242 as a module from the other environments. This can be done with the
4343 cookie-cutter generated configurations:
44- - Delete the *contents* of the cookie-cutter generated `terraform /` directories
44+ - Delete the *contents* of the cookie-cutter generated `tofu /` directories
4545 from the `production` and `staging` environments.
46- - Create a `main.tf` in those directories which uses `site/terraform /` as a
46+ - Create a `main.tf` in those directories which uses `site/tofu /` as a
4747 [module](https://opentofu.org/docs/language/modules/), e.g. :
4848
4949 ```
5050 ...
5151 module " cluster" {
52- source = " ../../site/terraform /"
52+ source = " ../../site/tofu /"
5353
5454 cluster_name = " foo"
5555 ...
5656 }
5757 ```
5858
59- Note that:
60- - Environment-specific variables (`cluster_name`) should be hardcoded
61- into the module block.
62- - Environment-independent variables (e.g. maybe `cluster_net` if the
63- same is used for staging and production) should be set as *defaults*
64- in `environments/site/terraform/variables.tf`, and then don' t need to
65- be passed in to the module.
59+ Note that:
60+ - Environment-specific variables (e.g. `cluster_name`) should be hardcoded
61+ into the module block.
62+ - Environment-independent variables should be set as *defaults*
63+ in `environments/site/tofu/variables.tf`, and then don' t need to
64+ be passed in to the module. Examples include `cluster_net` (assuming
65+ staging/production use the same network) and `cluster_image_ids` (because
66+ staging should test the image(s) which will subsequently be deployed
67+ to production after testing on a branch).
6668
6769- Vault-encrypt secrets. Running the `generate-passwords.yml` playbook creates
6870 a secrets file at `environments/$ENV/inventory/group_vars/all/secrets.yml`.
0 commit comments