Open KishoreNamala opened 3 years ago
Running mpdev apply -f configurations.yaml
generates jinja files. Within these jinja files we can reference the environment variables.
For example, we could reference the deployment in a gceStartupScript
in configurations.yaml
deploymentSpec:
singleVm:
gceStartupScript:
bashScriptContent: echo "{{ env["deployment"] }}"
If you unzip the template then the solution.jinja
file will contain
- key: startup-script
value: |-
#!/bin/bash
echo "{{ env["deployment"] }}"
We want to access the name of the deployment inside the code we are executing on the VM. How do we refer to that in the configuration.yaml
For deployment manager, we see the instructions here. https://cloud.google.com/deployment-manager/docs/configuration/templates/use-environment-variables
we are looking for something similar for the autogen config file.