Skip to content

Commit

Permalink
chore: improve pg health check
Browse files Browse the repository at this point in the history
  • Loading branch information
cao7113 committed Jul 13, 2024
1 parent 01d45c5 commit 2753880
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
name: Elixir CI
on:
# push:
# branches:
# - main
push:
branches:
- main
pull_request:
branches:
- main
Expand All @@ -22,7 +22,7 @@ jobs:
env:
POSTGRES_PASSWORD: postgres
options: >-
--health-cmd pg_isready
--health-cmd pg_isready -U postgres
--health-interval 10s
--health-timeout 5s
--health-retries 5
Expand Down
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ services:
- 25432:5432
# https://docs.docker.com/compose/compose-file/05-services/#healthcheck
healthcheck:
test: pg_isready
test: pg_isready -U postgres
interval: 1m30s
timeout: 10s
retries: 3
Expand Down

0 comments on commit 2753880

Please sign in to comment.