Created
May 14, 2021 19:33
-
-
Save s-aska/adf2e4b11e0681a3e70617a3331cd751 to your computer and use it in GitHub Desktop.
deploy-function ではじまるすべてのターゲットを実行する Makefile
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
PROJECT_ID="some-project-id" | |
ENV="dev" | |
TARGETS=$(shell grep -E '^deploy-function[a-zA-Z_-]+:' $(MAKEFILE_LIST) | cut -d : -f 1) | |
deploy-all: $(TARGETS) | |
deploy-function_some: | |
gcloud --project $(PROJECT_ID) functions deploy --region asia-northeast1 SomeFunction \ | |
--set-env-vars PROJECT_ID=$(PROJECT_ID),RUNTIME_ENVIRONMENT=$(ENV) \ | |
--runtime go111 \ | |
--timeout 540s \ | |
--trigger-resource "some-resources" \ | |
--trigger-event google.storage.object.finalize |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment