Add Docker configuration for Linkwarden and PostgreSQL with .gitignore

This commit is contained in:
2024-11-24 01:57:14 +01:00
parent 0e79c88bfb
commit 35931962ee
2 changed files with 35 additions and 0 deletions
+1
View File
@@ -0,0 +1 @@
./postgres_data
+34
View File
@@ -0,0 +1,34 @@
version: '3.8'
services:
linkwarden:
image: linkwarden/linkwarden:latest
container_name: linkwarden
ports:
- "3000:3000" # Cambia el puerto si es necesario
volumes:
- ./linkwarden_data:/app/data # Persistencia de datos
environment:
# Configuración del entorno de Linkwarden
NODE_ENV: production
ADMIN_EMAIL: admin@example.com # Cambia por tu correo de administrador
ADMIN_PASSWORD: adminpassword # Cambia esta contraseña por una segura
PORT: 3000
DATABASE_TYPE: postgres
DATABASE_URL: postgres://linkwarden:linkwardenpassword@postgres:5432/linkwarden
depends_on:
- postgres
restart: unless-stopped
postgres:
image: postgres:15
container_name: postgres
environment:
POSTGRES_USER: linkwarden
POSTGRES_PASSWORD: linkwardenpassword
POSTGRES_DB: linkwarden
volumes:
- ./postgres_data:/var/lib/postgresql/data # Persistencia de datos
restart: unless-stopped