Browse Source

🐛 deploy heroku error 200

main
guidezSeb 6 years ago
parent
commit
62769e6353
  1. 14
      .circleci/config.yml
  2. 2
      Procfile
  3. 1
      conduit/settings.py

14
.circleci/config.yml

@ -64,14 +64,14 @@ jobs:
name: Deploy main to heroku name: Deploy main to heroku
command: git push https://heroku:$HEROKU_API_KEY@git.heroku.com/$HEROKU_APP_NAME.git main command: git push https://heroku:$HEROKU_API_KEY@git.heroku.com/$HEROKU_APP_NAME.git main
- run:
- run:
name: Smoke test name: Smoke test
command: HTTPCODE=`curl -s -o /dev/null -w "%{http_code}" https://$HEROKU_APP_NAME.herokuapp.com/api/articles`
- run:
name: Smoke check
command: if [[ "$HTTPCODE" -ne 200 ]];then
echo "heroku app not responding, failing to deploy" && exit 1;
fi
command: |
HTTPCODE=`curl -s -o /dev/null -w "%{http_code}" https://$HEROKU_APP_NAME.herokuapp.com/api/articles`
if [ "$HTTPCODE" -ne 200 ];then
echo "heroku app not responding, failing deploy"
exit 1
fi
docker-build-push: docker-build-push:
working_directory: /dockerapp working_directory: /dockerapp
docker: docker:

2
Procfile

@ -1 +1 @@
web: flask db upgrade;gunicorn autoapp:app -b 0.0.0.0:$PORT -w 3
web: gunicorn autoapp:app -b 0.0.0.0:$PORT -w 3

1
conduit/settings.py

@ -25,7 +25,6 @@ class Config(object):
'http://localhost:4200', 'http://localhost:4200',
'http://0.0.0.0:4000', 'http://0.0.0.0:4000',
'http://localhost:4000', 'http://localhost:4000',
'https://reverent-swanson-5ad65a.netlify.app',
] ]
JWT_HEADER_TYPE = 'Token' JWT_HEADER_TYPE = 'Token'

Loading…
Cancel
Save