mirror of
https://github.com/furyhawk/cloudy.git
synced 2026-07-21 02:05:53 +00:00
feat: add nodepad service with Docker configuration and Traefik routing
This commit is contained in:
+1
-1
@@ -87,7 +87,7 @@ services:
|
||||
- traefik.swarm.network=traefik-public
|
||||
- traefik.constraint-label=traefik-public
|
||||
- traefik.http.routers.heynote.entrypoints=https
|
||||
- traefik.http.routers.heynote.rule=Host(`note.${DOMAIN}`) || Host(`note0.${DOMAIN}`) || Host(`n.${DOMAIN}`) || Host(`pad.${DOMAIN}`)
|
||||
- traefik.http.routers.heynote.rule=Host(`note.${DOMAIN}`) || Host(`note0.${DOMAIN}`) || Host(`n.${DOMAIN}`)
|
||||
# - traefik.http.routers.heynote.rule=HostRegexp(`note[0-9]{0,2}.${DOMAIN}`) || Host(`pad.${DOMAIN}`)
|
||||
- traefik.http.routers.heynote.tls.certresolver=le
|
||||
- traefik.http.routers.heynote.service=heynote_app
|
||||
|
||||
@@ -0,0 +1,18 @@
|
||||
FROM node:20-alpine AS builder
|
||||
WORKDIR /app
|
||||
COPY ./nodepad/package*.json ./
|
||||
RUN npm install
|
||||
COPY ./nodepad .
|
||||
RUN npm run build
|
||||
|
||||
FROM node:20-alpine AS runner
|
||||
WORKDIR /app
|
||||
ENV NODE_ENV=production
|
||||
COPY --from=builder /app/package*.json ./
|
||||
COPY --from=builder /app/.next ./.next
|
||||
COPY --from=builder /app/public ./public
|
||||
COPY --from=builder /app/node_modules ./node_modules
|
||||
COPY --from=builder /app/next.config.mjs ./
|
||||
|
||||
EXPOSE 3000
|
||||
CMD ["npm", "run", "start"]
|
||||
Submodule
+1
Submodule swarm/nodepad added at e72c2fdcc8
@@ -0,0 +1,30 @@
|
||||
services:
|
||||
nodepad:
|
||||
container_name: nodepad
|
||||
build:
|
||||
context: .
|
||||
dockerfile: inline.Dockerfile
|
||||
ports:
|
||||
- "3000:3000"
|
||||
environment:
|
||||
- NODE_ENV=production
|
||||
# Add your AI model API keys below if needed by the app:
|
||||
# - OPENAI_API_KEY=your_key_here
|
||||
# - ANTHROPIC_API_KEY=your_key_here
|
||||
restart: unless-stopped
|
||||
networks:
|
||||
- traefik-public
|
||||
deploy:
|
||||
labels:
|
||||
- traefik.enable=true
|
||||
- traefik.swarm.network=traefik-public
|
||||
- traefik.constraint-label=traefik-public
|
||||
- traefik.http.routers.nodepad.entrypoints=https
|
||||
- traefik.http.routers.nodepad.rule=Host(`pad.${DOMAIN}`)
|
||||
- traefik.http.routers.nodepad.tls.certresolver=le
|
||||
- traefik.http.routers.nodepad.service=nodepad_app
|
||||
- traefik.http.routers.nodepad-local.entrypoints=https
|
||||
- traefik.http.routers.nodepad-local.rule=Host(`pad.${LOCALDOMAIN}`)
|
||||
- traefik.http.routers.nodepad-local.tls=true
|
||||
- traefik.http.routers.nodepad-local.service=nodepad_app
|
||||
- traefik.http.services.nodepad_app.loadbalancer.server.port=3000
|
||||
Reference in New Issue
Block a user