Skip to content

Instantly share code, notes, and snippets.

@easikoglu
Last active July 18, 2019 08:31
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 easikoglu/469c54155720dfd634cf4c5a9962bb93 to your computer and use it in GitHub Desktop.
Save easikoglu/469c54155720dfd634cf4c5a9962bb93 to your computer and use it in GitHub Desktop.
image: atlassian/default-image:2
pipelines:
default:
- step:
name: Install NPM & Test
caches:
- node
script:
- npm install
- npm test
- step :
name: Run Grunt Task & Zip
script:
- npm install -g grunt-cli
- npm install grunt --save-dev
- grunt env-test
- zip -r /tmp/my-node-app.zip *
- step:
name: Upload to S3
image: atlassian/pipelines-awscli
script:
- aws --region $AWS_DEFAULT_REGION deploy push --application-name $APPLICATION_NAME --s3-location s3://$S3_BUCKET/my-node-app.zip --ignore-hidden-files
- step:
trigger: manual
name: Trigger CodeDeploy
image: atlassian/pipelines-awscli
script:
- aws deploy create-deployment --application-name $APPLICATION_NAME --s3-location bucket=$S3_BUCKET,key=my-node-app.zip,bundleType=zip --deployment-group-name $DEPLOYMENT_GROUP_NAME --ignore-application-stop-failures --description "Ignore ApplicationStop failures due to broken script"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment