I am using GCP deployment manager to deploy a gcp cloud storage bucket. My YAML file is uploaded in another existing gcp cloud storage bucket and I run following commands on gcp cloud shell in order to create deployment. I specify the link url in the commands to create deployment ( see below)
$gcloud config set project my-project-name
$gcloud deployment-manager deployments create bkt-deployer --config https://storage.cloud.google.com/mybucket/UCABkt-V4.yaml
And I get following error
Failed to parse YAML: mapping values are not allowed here
in "<unicode string>", line 11, column 14:
font-family: 'Open Sans';
^ (line: 11)
I figured that I get the YAML parse error despite specifying a wrong bucket name so I suspect that it is owing to issue with inaccessibility of YAML. I tried fixing permissions on bucket and individual YAML but no avail . I still get this error which in my opinion is really misleading.
While the actual YAML format isnt relevant , still jsut FYI my YAML file looks as follows (see code block)
resources:
- name: deployment-manager-bucket-2
type: storage.v1.bucket
properties:
predefinedAcl: projectPrivate
projection: full
location: US
storageClass: STANDARD
lifecycle:
rule:
- action:
type: SetStorageClass storage_class = "NEARLINE"
condition:
age: 30
- action:
type: SetStorageClass storage_class = "COLDLINE"
condition:
age: 90
so a couple questions
1) What is best way to provide YAML configuration to deployment manager? Is uploading yaml config file to a gcp object storage bucket and then specifying its link URL the way I did, an optimal option? or is there an alternative way for providing path of YAML to gcp cloud shell for deployment creation?
2) And assuming that eventually I get past that hurdle of specifying the deployment the path my YAML and ensuring there are no access and permission issues, does my YAML syntax look ok? Especially the lifecyle rule specification that assign Nearline and coldline storage classes on aging 30 and 90 days respectively
A huge thanks for your help.
Best regards
Yogesh