Actualiza toolkit operativo y documentación
This commit is contained in:
@@ -0,0 +1,6 @@
|
||||
.git
|
||||
node_modules
|
||||
.next
|
||||
*.md
|
||||
.gg
|
||||
tests
|
||||
@@ -0,0 +1,34 @@
|
||||
# oh-daddy (Next.js 16) - production image, built on the Coolify server.
|
||||
# No upstream Dockerfile exists (repo targets Railway/nixpacks), so this
|
||||
# replicates railway.json's startCommand contract: bash scripts/start.sh
|
||||
# (backgrounds the Inngest post-deploy re-sync, then execs `npm run start`).
|
||||
FROM node:22-alpine AS deps
|
||||
WORKDIR /app
|
||||
COPY package.json package-lock.json ./
|
||||
RUN npm ci
|
||||
|
||||
FROM node:22-alpine AS proddeps
|
||||
WORKDIR /app
|
||||
COPY package.json package-lock.json ./
|
||||
RUN npm ci --omit=dev
|
||||
|
||||
FROM node:22-alpine AS build
|
||||
WORKDIR /app
|
||||
ENV NEXT_TELEMETRY_DISABLED=1
|
||||
COPY --from=deps /app/node_modules ./node_modules
|
||||
COPY . .
|
||||
ARG NEXT_PUBLIC_APP_URL
|
||||
ENV NEXT_PUBLIC_APP_URL=$NEXT_PUBLIC_APP_URL
|
||||
RUN npm run build
|
||||
|
||||
FROM node:22-alpine AS runner
|
||||
WORKDIR /app
|
||||
RUN apk add --no-cache bash
|
||||
ENV NODE_ENV=production PORT=3000 NEXT_TELEMETRY_DISABLED=1
|
||||
COPY --from=proddeps /app/node_modules ./node_modules
|
||||
COPY --from=build /app/.next ./.next
|
||||
COPY --from=build /app/public ./public
|
||||
COPY --from=build /app/package.json ./package.json
|
||||
COPY --from=build /app/scripts ./scripts
|
||||
EXPOSE 3000
|
||||
CMD ["bash", "scripts/start.sh"]
|
||||
@@ -0,0 +1,108 @@
|
||||
# oh-daddy stack for Coolify (service type: docker compose, prebuilt/local images)
|
||||
# Upstream: https://github.com/KenKaiii/oh-daddy
|
||||
# App image `oh-daddy-app:local` is built on the server (Deploy-OhDaddy flow,
|
||||
# same pattern as Deploy-SoloLeveling.ps1) - Coolify's own deploy cannot pull it.
|
||||
# All secrets come from Coolify service env vars (is_literal) / .env in the
|
||||
# service dir; nothing is hardcoded here.
|
||||
#
|
||||
# Hard rules honored (docs/AGENTS-coolify-apps.md):
|
||||
# - no published 80/443; Traefik routes via SERVICE_FQDN_APP_3000 -> port 3000
|
||||
# - siblings reached by Docker service name (db, inngest, inngest-db, inngest-redis)
|
||||
# - named volumes for everything that must survive redeploys
|
||||
|
||||
services:
|
||||
app:
|
||||
image: oh-daddy-app:local
|
||||
restart: unless-stopped
|
||||
environment:
|
||||
- SERVICE_FQDN_APP_3000
|
||||
- PORT=3000
|
||||
- NODE_ENV=production
|
||||
- DATABASE_URL=${DATABASE_URL}
|
||||
- APP_ENCRYPTION_KEY=${APP_ENCRYPTION_KEY}
|
||||
- ADMIN_PASSWORD=${ADMIN_PASSWORD}
|
||||
- INNGEST_BASE_URL=${INNGEST_BASE_URL}
|
||||
- INNGEST_SIGNING_KEY=${INNGEST_SIGNING_KEY}
|
||||
- INNGEST_EVENT_KEY=${INNGEST_EVENT_KEY}
|
||||
- NEXT_PUBLIC_APP_URL=${NEXT_PUBLIC_APP_URL}
|
||||
expose:
|
||||
- "3000"
|
||||
healthcheck:
|
||||
test: ["CMD", "wget", "-qO-", "http://127.0.0.1:3000/login"]
|
||||
interval: 30s
|
||||
timeout: 5s
|
||||
retries: 3
|
||||
start_period: 60s
|
||||
depends_on:
|
||||
db:
|
||||
condition: service_healthy
|
||||
|
||||
db:
|
||||
image: postgres:17-alpine
|
||||
restart: unless-stopped
|
||||
environment:
|
||||
- POSTGRES_DB=ohdaddy
|
||||
- POSTGRES_USER=ohdaddy
|
||||
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
|
||||
volumes:
|
||||
- oh-daddy-db-data:/var/lib/postgresql/data
|
||||
healthcheck:
|
||||
test: ["CMD-SHELL", "pg_isready -U ohdaddy -d ohdaddy"]
|
||||
interval: 5s
|
||||
timeout: 5s
|
||||
retries: 12
|
||||
|
||||
# Self-hosted Inngest engine (NOT Inngest Cloud) - internal only, no FQDN.
|
||||
inngest:
|
||||
image: inngest/inngest:v1.44.0
|
||||
restart: unless-stopped
|
||||
command: ["inngest", "start"]
|
||||
environment:
|
||||
- INNGEST_SIGNING_KEY=${INNGEST_SIGNING_KEY}
|
||||
- INNGEST_EVENT_KEY=${INNGEST_EVENT_KEY}
|
||||
- INNGEST_POSTGRES_URI=${INNGEST_POSTGRES_URI}
|
||||
- INNGEST_REDIS_URI=redis://inngest-redis:6379
|
||||
expose:
|
||||
- "8288"
|
||||
healthcheck:
|
||||
test: ["CMD", "inngest", "alpha", "doctor", "healthcheck"]
|
||||
interval: 30s
|
||||
timeout: 10s
|
||||
retries: 3
|
||||
start_period: 40s
|
||||
depends_on:
|
||||
inngest-db:
|
||||
condition: service_healthy
|
||||
inngest-redis:
|
||||
condition: service_healthy
|
||||
|
||||
inngest-db:
|
||||
image: postgres:17-alpine
|
||||
restart: unless-stopped
|
||||
environment:
|
||||
- POSTGRES_DB=inngest
|
||||
- POSTGRES_USER=inngest
|
||||
- POSTGRES_PASSWORD=${INNGEST_DB_PASSWORD}
|
||||
volumes:
|
||||
- oh-daddy-inngest-pg-data:/var/lib/postgresql/data
|
||||
healthcheck:
|
||||
test: ["CMD-SHELL", "pg_isready -U inngest -d inngest"]
|
||||
interval: 5s
|
||||
timeout: 5s
|
||||
retries: 12
|
||||
|
||||
inngest-redis:
|
||||
image: redis:7-alpine
|
||||
restart: unless-stopped
|
||||
volumes:
|
||||
- oh-daddy-inngest-redis-data:/data
|
||||
healthcheck:
|
||||
test: ["CMD", "redis-cli", "ping"]
|
||||
interval: 5s
|
||||
timeout: 3s
|
||||
retries: 5
|
||||
|
||||
volumes:
|
||||
oh-daddy-db-data: {}
|
||||
oh-daddy-inngest-pg-data: {}
|
||||
oh-daddy-inngest-redis-data: {}
|
||||
Reference in New Issue
Block a user