version: '3.8'

services:
  tina:
    image: node:20-alpine
    working_dir: /app
    volumes:
      - .:/app
      - /app/node_modules
    ports:
      - "4001:4001"
    environment:
      - NODE_ENV=production
    command: >
      sh -c "npm install -g pnpm && 
             pnpm install && 
             pnpm tinacms dev --host 0.0.0.0 --port 4001"
    restart: unless-stopped
