是否可以將雲功能trigger-bucket
參數配置爲GCS存儲桶中的文件夾?在文件夾上觸發雲端功能 - 有可能嗎?
例如,假設我們有以下幾點:
gs://a_bucket/a_folder
不是部署時設置--trigger-bucket gs://a_bucket
的,我需要在文件夾級別即--trigger-bucket gs://a_bucket/a_folder/
來設置。
但是,我得到的錯誤:
ERROR: (gcloud.beta.functions.deploy) argument --trigger-bucket: Invalid value 'gs://a_bucket/a_folder/': Bucket must only contain lower case Latin letters, digits and characters . _ -. It must start and end with a letter or digit and be from 3 to 232 characters long. You may optionally prepend the bucket name with gs:// and append/at the end.
https://cloud.google.com/sdk/gcloud/reference/beta/functions/deploy