1
0
Fork 0
mirror of https://github.com/maybe-finance/maybe.git synced 2025-08-05 05:25:24 +02:00

Self Hosting: Docker Compose setup and flow (#640)

* feat(self-hosting): add docker-compose and ghcr release workflow

* WIP: address review comments

* WIP: fix linting
This commit is contained in:
Radu C. Martin 2024-05-07 00:52:14 +02:00 committed by GitHub
parent 0616d3e2b7
commit 930dc26828
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
7 changed files with 237 additions and 6 deletions

View file

@ -0,0 +1,35 @@
services:
app:
image: ghcr.io/maybe-finance/maybe:latest
ports:
- 127.0.0.1:3000:3000
restart: unless-stopped
env_file:
- .env
environment:
DB_HOST: "postgres"
RAILS_ENV: "production"
RAILS_FORCE_SSL: false
RAILS_ASSUME_SSL: false
depends_on:
postgres:
condition: service_healthy
postgres:
image: postgres:16
restart: unless-stopped
volumes:
- postgres-data:/var/lib/postgresql/data
environment:
POSTGRES_USER: ${POSTGRES_USER:?}
POSTGRES_DB: ${POSTGRES_DB:-postgres}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:?}
healthcheck:
test: [ "CMD-SHELL", "pg_isready -U $$POSTGRES_USER" ]
interval: 5s
timeout: 5s
retries: 5
volumes:
postgres-data: