Skip to content

Commit

Permalink
Show app logs on failure
Browse files Browse the repository at this point in the history
  • Loading branch information
AmirrezaNasiri authored Dec 10, 2023
1 parent e4a3e66 commit b88af37
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion .github/workflows/golang-ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,17 @@ jobs:
- name: Run integration test
working-directory: .data/MyGolangApp
run: |
go run main.go &
go run main.go > /tmp/app-log &
sleep 2
curl --connect-timeout 10 http://0.0.0.0:8080
if [ $? -eq 0 ]; then
cat /tmp/app-log
echo "Curl succeeded."
else
cat /tmp/app-log
echo "Curl failed!"
exit 1
fi

0 comments on commit b88af37

Please sign in to comment.