Browse Source

Deploy Heroku step and Hello netlify

main
sipe-daniel 6 years ago
parent
commit
2a934047c8
  1. 54
      .circleci/config.yml
  2. 5
      testMaster-III-TP-CD.sh

54
.circleci/config.yml

@ -54,7 +54,7 @@ jobs:
at: /tmp
- run:
name: Deploy app
command: echo todo && false
command: npx netlify-cli deploy --prod --dir /tmp/server-doc --message "déploiement" --site "0e3c2f9f-5400-4203-9deb-04b416524c66"
back-test-unit:
docker:
- image: circleci/node:dubnium-browsers
@ -121,55 +121,7 @@ jobs:
- checkout
- run:
name: Heroku Deploy
command: echo todo && false
command: git push https://heroku:5730951c-f7d5-4cfd-8aea-c0cae3adc0d2@git.heroku.com/whispering-garden-62583.git HEAD:master
- run:
name: Smoke Test
command: echo todo && false
workflows:
version: 2
build-test-and-lint:
jobs:
- build
- back-test-unit:
requires:
- build
- back-test-e2e:
requires:
- build
- lint:
requires:
- build
- docker-build-and-push:
requires:
- build
- lint
- back-test-e2e
- back-test-unit
filters:
branches:
only: main
- back-deploy-heroku:
requires:
- build
- lint
- back-test-e2e
- back-test-unit
filters:
branches:
only: main
- server-doc-build:
requires:
- build
- lint
- back-test-e2e
- back-test-unit
filters:
branches:
only: main
- server-doc-deploy:
requires:
- server-doc-build
filters:
branches:
only: main
command: ./testMaster-III-TP-CD.sh

5
testMaster-III-TP-CD.sh

@ -0,0 +1,5 @@
HTTPCODE=`curl -s -o /dev/null -w "%{http_code}" https://$HEROKU_APP_NAME.herokuapp.com/`
if [ "$HTTPCODE" -ne 200 ];then
echo "heroku app not responding, failing deploy"
exit 1
fi
Loading…
Cancel
Save