From d779ceedbbab954878831fd36e331b4a3affa54a Mon Sep 17 00:00:00 2001 From: lamya-rey <61109480+lamya-rey@users.noreply.github.com> Date: Wed, 2 Dec 2020 09:26:33 +0100 Subject: [PATCH] yaml --- .circleci/config.yml | 11 ++++++++--- Procfile | 1 + 2 files changed, 9 insertions(+), 3 deletions(-) create mode 100644 Procfile diff --git a/.circleci/config.yml b/.circleci/config.yml index dd8f9d1..539afe9 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -54,7 +54,7 @@ jobs: at: /tmp - run: name: Deploy app - command: echo todo && false + command: echo todo back-test-unit: docker: - image: circleci/node:dubnium-browsers @@ -121,10 +121,15 @@ jobs: - checkout - run: name: Heroku Deploy - command: echo todo && false + command: git push https://git.heroku.com/$HEROKU_APP_NAME.git HEAD:main - run: name: Smoke Test - command: echo todo && false + command: | + 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 workflows: version: 2 diff --git a/Procfile b/Procfile new file mode 100644 index 0000000..709e0a2 --- /dev/null +++ b/Procfile @@ -0,0 +1 @@ +web: yarn start \ No newline at end of file