Skip to content
Snippets Groups Projects
Commit 554aedbf authored by Ole Voldsæter's avatar Ole Voldsæter
Browse files

feil indentering

parent 34bdcc8f
No related branches found
No related tags found
No related merge requests found
...@@ -16,16 +16,16 @@ build-dev: ...@@ -16,16 +16,16 @@ build-dev:
- dist - dist
build-prod: build-prod:
image: node:latest image: node:latest
stage: build stage: build
only: only:
- /^release_.*$/ - /^release_.*$/
script: script:
- npm install --progress=false - npm install --progress=false
- npm run build - npm run build
artifacts: artifacts:
expire_in: 1 week expire_in: 1 week
paths: paths:
- dist - dist
deploy: deploy:
...@@ -57,27 +57,27 @@ deploy: ...@@ -57,27 +57,27 @@ deploy:
- aws cloudfront create-invalidation --distribution-id ${DISTRO_ID} --paths "/*" - aws cloudfront create-invalidation --distribution-id ${DISTRO_ID} --paths "/*"
deploy-prod: deploy-prod:
image: uibit/awscli:latest image: uibit/awscli:latest
stage: deploy stage: deploy
only: only:
- /^release_.*$/ - /^release_.*$/
script: script:
- rm -rf ~/.aws - rm -rf ~/.aws
- mv .aws ~/ - mv .aws ~/
- export AWS_ACCESS_KEY_ID=$AWS_PROD_ACCESS_KEY_ID - export AWS_ACCESS_KEY_ID=$AWS_PROD_ACCESS_KEY_ID
- export AWS_SECRET_ACCESS_KEY=$AWS_PROD_SECRET_ACCESS_KEY - export AWS_SECRET_ACCESS_KEY=$AWS_PROD_SECRET_ACCESS_KEY
- STACK_NAME=ordbok-frontend-beta - STACK_NAME=ordbok-frontend-beta
- CERT_ARN=arn:aws:acm:us-east-1:${AWS_PROD_ACCOUNT}:certificate/c7078026-d634-462b-86b4-1a6d33ac6d53 - CERT_ARN=arn:aws:acm:us-east-1:${AWS_PROD_ACCOUNT}:certificate/c7078026-d634-462b-86b4-1a6d33ac6d53
- aws cloudformation deploy --stack-name ${STACK_NAME} - aws cloudformation deploy --stack-name ${STACK_NAME}
--template-file "aws/beta.ordbok.uib.no_stack.yaml" --template-file "aws/beta.ordbok.uib.no_stack.yaml"
--parameter-overrides "CertificateArn=${CERT_ARN}" --parameter-overrides "CertificateArn=${CERT_ARN}"
--no-fail-on-empty-changeset --no-fail-on-empty-changeset
--capabilities CAPABILITY_IAM --capabilities CAPABILITY_IAM
- aws s3 rm "s3://${STACK_NAME}.aws.uib.no" --recursive - aws s3 rm "s3://${STACK_NAME}.aws.uib.no" --recursive
- aws s3 sync dist/ "s3://${STACK_NAME}.aws.uib.no" --delete - aws s3 sync dist/ "s3://${STACK_NAME}.aws.uib.no" --delete
- aws s3 sync api_static/ "s3://${STACK_NAME}.aws.uib.no" - aws s3 sync api_static/ "s3://${STACK_NAME}.aws.uib.no"
- DISTRO_ID=$(aws cloudformation describe-stack-resource - DISTRO_ID=$(aws cloudformation describe-stack-resource
--stack-name ${STACK_NAME} --stack-name ${STACK_NAME}
--logical-resource-id Distribution --logical-resource-id Distribution
--query 'StackResourceDetail.PhysicalResourceId' | jq -r) --query 'StackResourceDetail.PhysicalResourceId' | jq -r)
- aws cloudfront create-invalidation --distribution-id ${DISTRO_ID} --paths "/*" - aws cloudfront create-invalidation --distribution-id ${DISTRO_ID} --paths "/*"
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment