version: "3" services: db: image: postgres:12 restart: always volumes: - db:/var/lib/postgresql/data environment: - POSTGRES_USER=kepton - POSTGRES_PASSWORD=password ports: - 5432:5432 redis: image: redis:5-alpine command: redis-server --appendonly yes restart: always volumes: - redis:/data ports: - 6379:6379 volumes: redis: db: