Skip to content

Commit

Permalink
fixup!test: setup mongodb server - debug 2
Browse files Browse the repository at this point in the history
  • Loading branch information
o-orand committed Sep 25, 2024
1 parent e52d891 commit faf9e22
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions .github/workflows/build-using-cnb-buildpack.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,23 +69,29 @@ jobs:
docker run -d --rm -e PORT=80 --env-file vcap-service.env -p 8080:80 --name "cnb-app" ${{env.CNB_IMAGE_NAME}}
docker logs -f cnb-app &> cnb-app.log &
docker ps -a
export APP=http://localhost:8080
export APP="http://127.0.0.1:8080"
exit_status=0
if nc -vz 127.0.0.1 8080;then echo "port 8080 available";else echo "port 8080 UNAVAILABLE";exit_status=1;fi
if nc -vz 127.0.0.1 ${SERVICE_PORT};then echo "port ${SERVICE_PORT} available";else echo "port ${SERVICE_PORT} UNAVAILABLE";exit_status=1;fi
echo "Create using 'curl -X POST $APP/myCollection'"
if ! curl -vvv -X POST $APP/myCollection;then
echo "Create failed"
exit_status=1
else
echo "Create successful"
fi
echo "Delete using 'curl -X DELETE $APP/myCollection'"
if ! curl -vvv -X DELETE $APP/myCollection;then
echo "Delete failed"
exit_status=1
else
echo "Delete successful"
fi
if nc -vz 127.0.0.1 8080;then echo "port 8080 available";else echo "port 8080 UNAVAILABLE";fi
if nc -vz 127.0.0.1 ${SERVICE_PORT};then echo "port ${SERVICE_PORT} available";else echo "port ${SERVICE_PORT} UNAVAILABLE";fi
cat cnb-app.log
echo "Dumping logs using docker logs cnb-app"
docker logs cnb-app
exit $exit_status
-
name: Tag version ${{github.ref_name}}
if: github.ref_type == 'tag'
Expand Down

0 comments on commit faf9e22

Please sign in to comment.