Skip to content

Instantly share code, notes, and snippets.

@oismaelash
Created November 14, 2025 14:35
Show Gist options
  • Select an option

  • Save oismaelash/54d41be1e073dc83515c3c5750c22bd3 to your computer and use it in GitHub Desktop.

Select an option

Save oismaelash/54d41be1e073dc83515c3c5750c22bd3 to your computer and use it in GitHub Desktop.
docker-compose.yml
services:
api:
# build: .
image: ghcr.io/oismaelash/shorterner-api:latest
ports:
- "3000:3000"
environment:
BASE_URL: "http://localhost:3000"
REDIS_HOST: redis
POSTGRES_HOST: postgres
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_DB: shortener
depends_on:
- redis
- postgres
restart: unless-stopped
redis:
image: redis:7
ports:
- "6379:6379"
restart: unless-stopped
postgres:
image: postgres:15
environment:
POSTGRES_PASSWORD: postgres
POSTGRES_DB: shortener
ports:
- "5432:5432"
volumes:
- postgres_data:/var/lib/postgresql/data
restart: unless-stopped
volumes:
postgres_data:
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment