Created
August 5, 2022 06:04
-
-
Save biblia19/41a51694dd35cb8b804ce1797c212e52 to your computer and use it in GitHub Desktop.
n8n_with_PostgresSQL
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# https://github.com/n8n-io/n8n/blob/master/docker/compose/withPostgres/docker-compose.yml | |
# https://docs.n8n.io/hosting/installation/docker/#postgresdb | |
version: '3.3' | |
services: | |
n8n: | |
image: n8nio/n8n | |
container_name: n8n | |
ports: | |
- '5678:5678' | |
environment: | |
- DB_TYPE=postgresdb | |
- DB_POSTGRESDB_DATABASE=<POSTGRES_DATABASE> | |
- DB_POSTGRESDB_HOST=db | |
- DB_POSTGRESDB_PORT=5432 | |
- DB_POSTGRESDB_USER=<POSTGRES_USER> | |
- DB_POSTGRESDB_PASSWORD=<POSTGRES_PASSWORD> | |
- N8N_HOST=<HOST> | |
- N8N_PORT=<PORT> | |
- GENERIC_TIMEZONE=Asia/Seoul | |
- TZ=Asia/Seoul | |
volumes: | |
- <N8N_SAVE_DATA_DIR>:/home/node/.n8n | |
depends_on: | |
- db | |
db: | |
image: postgres:14 | |
container_name: n8n_db | |
restart: always | |
environment: | |
- POSTGRES_USER=<POSTGRES_USER> | |
- POSTGRES_PASSWORD=<POSTGRES_PASSWORD> | |
- POSTGRES_DB=<POSTGRES_DATABASE> | |
volumes: | |
- <N8N_SAVE_DB_DIR>:/var/lib/postgresql/data |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment