Skip to content

Commit

Permalink
Restucture
Browse files Browse the repository at this point in the history
  • Loading branch information
parberge committed Sep 26, 2023
1 parent e9caae2 commit d247f7f
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 16 deletions.
23 changes: 7 additions & 16 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,21 +6,12 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- run: |
- name: Setup environment
run: |
cp .env-example .env
docker compose up --build -d
- name: Make sure we frontend responds
- name: Build and start the stack
run: |
docker-compose up --build -d
- name: Verify that the stack is running
run: |
SUCCESS=0
for try in {1..3}; do
status_code=$(curl --write-out %{http_code} --silent --output /dev/null http://localhost:3000)
if [[ "$status_code" -eq 200 ]] ; then
SUCCESS=1
break
else
echo "Attempt $try failed with status code $status_code"
fi
sleep 1
done
bash ci-verify.sh
13 changes: 13 additions & 0 deletions ci-verify.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@

SUCCESS=0

for try in {1..3}; do
status_code=$(curl --write-out %{http_code} --silent --output /dev/null http://localhost:3000)
if [[ "$status_code" -eq 200 ]] ; then
SUCCESS=1
break
else
echo "Attempt $try failed with status code $status_code"
fi
sleep 1
done

0 comments on commit d247f7f

Please sign in to comment.