From 3662e46e7e8b9c1fd3c440b37980fe471f74793d Mon Sep 17 00:00:00 2001 From: Damian Lozinski Date: Fri, 15 Nov 2019 17:01:32 +0100 Subject: [PATCH] Add aws profile handling --- Makefile | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 8eb1cf7..df4a5e3 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,5 @@ STACK_NAME ?= ffmpeg-lambda-layer +AWS_PROFILE ?= default clean: rm -rf build @@ -10,11 +11,11 @@ build/layer/bin/ffmpeg: mv build/ffmpeg*/ffmpeg build/ffmpeg*/ffprobe build/layer/bin build/output.yaml: template.yaml build/layer/bin/ffmpeg - aws cloudformation package --template $< --s3-bucket $(DEPLOYMENT_BUCKET) --output-template-file $@ + aws --profile $(AWS_PROFILE) cloudformation package --template $< --s3-bucket $(DEPLOYMENT_BUCKET) --output-template-file $@ deploy: build/output.yaml - aws cloudformation deploy --template $< --stack-name $(STACK_NAME) - aws cloudformation describe-stacks --stack-name $(STACK_NAME) --query Stacks[].Outputs --output table + aws --profile $(AWS_PROFILE) cloudformation deploy --template $< --stack-name $(STACK_NAME) + aws --profile $(AWS_PROFILE) cloudformation describe-stacks --stack-name $(STACK_NAME) --query Stacks[].Outputs --output table deploy-example: cd example && \