Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,26 @@ jobs:
- install
timeout-minutes: 15
runs-on: ubuntu-latest
services:
postgres:
image: postgres:latest # should be the same version as used in .github/workflows, docker-compose.test.yml, Dockerfile and live
env:
POSTGRES_DB: 'test'
POSTGRES_USER: 'root'
POSTGRES_PASSWORD: 'root'
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
ports:
- 5432:5432
integresql:
image: ghcr.io/allaboutapps/integresql:v1.1.0
env:
PGHOST: 'postgres'
PGUSER: 'root'
PGPASSWORD: 'root'
steps:
- uses: actions/checkout@v4
- uses: ./.github/actions/setup
Expand Down
37 changes: 37 additions & 0 deletions docker-compose.test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
version: '3.4'
services:
integresql:
image: ghcr.io/allaboutapps/integresql:v1.1.0
ports:
- '5000:5000'
depends_on:
- postgres
environment:
PGHOST: postgres
PGUSER: root
PGPASSWORD: root

postgres:
image: postgres:latest # should be the same version as used live
# ATTENTION
# fsync=off, synchronous_commit=off and full_page_writes=off
# gives us a major speed up during local development and testing (~30%),
# however you should NEVER use these settings in PRODUCTION unless
# you want to have CORRUPTED data.
# DO NOT COPY/PASTE THIS BLINDLY.
# YOU HAVE BEEN WARNED.
# Apply some performance improvements to pg as these guarantees are not needed while running locally
command: "postgres -c 'shared_buffers=128MB' -c 'fsync=off' -c 'synchronous_commit=off' -c 'full_page_writes=off' -c 'max_connections=100' -c 'client_min_messages=warning'"
expose:
- '5432'
ports:
- '5432:5432'
environment:
POSTGRES_DB: test
POSTGRES_USER: root
POSTGRES_PASSWORD: root
volumes:
- postgres-volume:/var/lib/postgresql/data

volumes:
postgres-volume: # declare a named volume to persist DB data
Loading
Loading