のような複数行の変数、でYAMLと神社とGoogleのデプロイメント・マネージャーを使用しようとすると:Googleの展開マネージャー:MANIFEST_EXPANSION_USER_ERROR複数行変数
startup_script_passed_as_variable: |
line 1
line 2
line 3
以降:
{% if 'startup_script_passed_as_variable' in properties %}
- key: startup-script
value: {{properties['startup_script_passed_as_variable'] }}
{% endif %}
がMANIFEST_EXPANSION_USER_ERROR
を与えます:
ERROR: (gcloud.deployment-manager.deployments.create) Error in Operation operation-1432566282260-52e8eed22aa20-e6892512-baf7134:
MANIFEST_EXPANSION_USER_ERROR
Manifest expansion encountered the following errors: while scanning a simple key in "" could not found expected ':' in ""
試行):
{% if 'startup_script' in properties %}
- key: startup-script
value: {{ startup_script_passed_as_variable }}
{% endif %}
も
{% if 'startup_script' in properties %}
- key: startup-script
value: |
{{ startup_script_passed_as_variable }}
{% endif %}
と
{% if 'startup_script' in properties %}
- key: startup-script
value: |
{{ startup_script_passed_as_variable|indent(12) }}
{% endif %}
これは私がやったことです! (スクリプトを配列として渡し、それぞれの行にアイテムを渡します) –