Advertisement
Guest User

Untitled

a guest
Mar 22nd, 2018
99
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.81 KB | None | 0 0
  1. version: 0.2
  2.  
  3. phases:
  4. install:
  5. commands:
  6. # Install dependencies needed for running tests
  7. - npm install
  8.  
  9. # Upgrade AWS CLI to the latest version
  10. - pip install --upgrade awscli
  11. pre_build:
  12. commands:
  13. # Discover and run unit tests in the 'tests' directory
  14. - npm test
  15. build:
  16. commands:
  17. # Use AWS SAM to package the application by using AWS CloudFormation
  18. - aws s3 cp --recursive public/ s3://$WEBSITE_S3_BUCKET/public/ --grants read=uri=http://acs.amazonaws.com/groups/global/AllUsers
  19. - sed -i -e "s|assets/|$WEBSITE_S3_PREFIX/public/assets/|g" public/index.html
  20. - aws cloudformation package --template template.yml --s3-bucket $S3_BUCKET --output-template template-export.yml
  21.  
  22. artifacts:
  23. type: zip
  24. files:
  25. - template-export.yml
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement