Files
ap_pos/docker-compose.yml
Marco Gallegos a12ac988eb fix: Update Docker configuration for persistent data storage
- Update docker-compose.yml to use latest image marcogll/ap-pos:latest
- Change from bind mount to named volume for better data persistence
- Add proper volumes section to ensure database survives container restarts
- Update README with corrected deployment instructions

This fixes the issue where imported JSON products were lost on container restart.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-09-08 19:05:19 -06:00

26 lines
604 B
YAML

version: '3.8'
services:
ap-pos:
image: marcogll/ap-pos:latest
container_name: ap-pos
restart: unless-stopped
ports:
- "3111:3111"
environment:
NODE_ENV: production
SESSION_SECRET: ${SESSION_SECRET:-your-very-secret-key-change-it-in-production}
DB_PATH: /app/data/ap-pos.db
volumes:
- ap_pos_data:/app/data
healthcheck:
test: ["CMD", "wget", "--quiet", "--tries=1", "--spider", "http://localhost:3111/login.html"]
interval: 30s
timeout: 10s
retries: 3
start_period: 40s
volumes:
ap_pos_data:
driver: local