Skip to content

Instantly share code, notes, and snippets.

@garystafford
Last active August 11, 2018 02:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save garystafford/2590903def7ee27f3d38cab956db84ae to your computer and use it in GitHub Desktop.
Save garystafford/2590903def7ee27f3d38cab956db84ae to your computer and use it in GitHub Desktop.
#!/usr/bin/env sh
# author: Gary A. Stafford
# site: https://programmaticponderings.com
# license: MIT License
set -ex
# Set constants
REGION="<your_region>"
FUNCTION_NAME="<your_function_name>"
# Deploy the Google Cloud Function
gcloud beta functions deploy ${FUNCTION_NAME} \
--runtime nodejs8 \
--region ${REGION} \
--trigger-http \
--memory 256MB \
--env-vars-file .env.yaml
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment