I would like to compress and upload a cloud function to a bucket. But not deploy the function.
I am going to deploy it with a Deployment Manager
template: type: 'gcp-types/cloudfunctions-v1:projects.locations.functions'
.
I can't find an option in gcloud cli to zip a folder and ignore files in .gcloudignore
if I create the zip manually, something like git archive
.
I read google cloud functions command to package without deploying but I don't know how to ignore the files if I create the zip manually.
Thanks in advance.
gcloud cp
if you already have it, have you tried doing so?gsutil cp
but the main problem is create the zip and ignore files in.gcloudignore
, for now I am ignoring files manual with-x
modifier, but it isn't sync with.gcloudignore
so I need to update both places when need to change ignored files.