mirror of
https://github.com/Memo-2023/mana-monorepo.git
synced 2026-05-14 19:41:09 +02:00
feat(games): add whopixels hosting at whopxl.mana.how
Dockerfile, docker-compose service (port 5100), Caddy and cloudflared routing for the WhoPixels game. PORT is now configurable via env var. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
2eb280cc07
commit
d9ccb5e31b
59 changed files with 348 additions and 77 deletions
|
|
@ -111,6 +111,13 @@ playground.mana.how {
|
|||
reverse_proxy localhost:5090
|
||||
}
|
||||
|
||||
# ============================================
|
||||
# Games
|
||||
# ============================================
|
||||
whopxl.mana.how {
|
||||
reverse_proxy localhost:5100
|
||||
}
|
||||
|
||||
# ============================================
|
||||
# Monitoring & Analytics
|
||||
# ============================================
|
||||
|
|
|
|||
|
|
@ -1,11 +1,10 @@
|
|||
# Multi-stage Dockerfile for Astro landing pages # This is a template - copy and customize for each
|
||||
landing page # ============================================ # Build Stage #
|
||||
============================================ FROM node:20-alpine AS builder # Install pnpm RUN
|
||||
corepack enable && corepack prepare pnpm@9.15.0 --activate WORKDIR /app # Copy workspace files COPY
|
||||
pnpm-workspace.yaml ./ COPY package.json ./ COPY pnpm-lock.yaml ./ # Copy all shared packages COPY
|
||||
packages/ ./packages/ # Copy the specific landing page ARG SERVICE_PATH COPY ${SERVICE_PATH} ./${
|
||||
SERVICE_PATH
|
||||
}
|
||||
# syntax=docker/dockerfile:1 # Multi-stage Dockerfile for Astro landing pages # This is a template -
|
||||
copy and customize for each landing page # ============================================ # Build
|
||||
Stage # ============================================ FROM node:20-alpine AS builder # Install pnpm
|
||||
RUN corepack enable && corepack prepare pnpm@9.15.0 --activate WORKDIR /app # Copy workspace files
|
||||
COPY pnpm-workspace.yaml ./ COPY package.json ./ COPY pnpm-lock.yaml ./ # Copy all shared packages
|
||||
COPY packages/ ./packages/ # Copy the specific landing page ARG SERVICE_PATH COPY ${SERVICE_PATH}
|
||||
./${SERVICE_PATH}
|
||||
# Install all dependencies RUN pnpm install --frozen-lockfile # Build shared packages first RUN pnpm
|
||||
run build:packages # Build the landing page WORKDIR /app/${SERVICE_PATH}
|
||||
RUN pnpm build # ============================================ # Production Stage - Nginx # ============================================
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
# syntax=docker/dockerfile:1
|
||||
# Multi-stage Dockerfile for NestJS backend services
|
||||
# This is a template - copy and customize for each backend service
|
||||
|
||||
|
|
@ -26,7 +27,7 @@ ARG SERVICE_PATH
|
|||
COPY ${SERVICE_PATH} ./${SERVICE_PATH}
|
||||
|
||||
# Install all dependencies (including devDependencies for build)
|
||||
RUN pnpm install --frozen-lockfile
|
||||
RUN --mount=type=cache,id=pnpm,target=/root/.local/share/pnpm/store pnpm install --frozen-lockfile
|
||||
|
||||
# Build shared packages first
|
||||
RUN pnpm run build:packages
|
||||
|
|
@ -60,7 +61,7 @@ ARG SERVICE_PATH
|
|||
COPY --from=builder /app/${SERVICE_PATH} ./${SERVICE_PATH}
|
||||
|
||||
# Install production dependencies only
|
||||
RUN pnpm install --prod --frozen-lockfile
|
||||
RUN --mount=type=cache,id=pnpm,target=/root/.local/share/pnpm/store pnpm install --prod --frozen-lockfile
|
||||
|
||||
# Create non-root user
|
||||
RUN addgroup -g 1001 -S nodejs && \
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
# syntax=docker/dockerfile:1
|
||||
# Multi-stage Dockerfile for SvelteKit web applications
|
||||
# This is a template - copy and customize for each web app
|
||||
|
||||
|
|
@ -24,7 +25,7 @@ ARG SERVICE_PATH
|
|||
COPY ${SERVICE_PATH} ./${SERVICE_PATH}
|
||||
|
||||
# Install all dependencies
|
||||
RUN pnpm install --frozen-lockfile
|
||||
RUN --mount=type=cache,id=pnpm,target=/root/.local/share/pnpm/store pnpm install --frozen-lockfile
|
||||
|
||||
# Build shared packages first
|
||||
RUN pnpm run build:packages
|
||||
|
|
@ -58,7 +59,7 @@ COPY --from=builder /app/${SERVICE_PATH}/build ./${SERVICE_PATH}/build
|
|||
COPY --from=builder /app/${SERVICE_PATH}/package.json ./${SERVICE_PATH}/package.json
|
||||
|
||||
# Install production dependencies
|
||||
RUN pnpm install --prod --frozen-lockfile
|
||||
RUN --mount=type=cache,id=pnpm,target=/root/.local/share/pnpm/store pnpm install --prod --frozen-lockfile
|
||||
|
||||
# Create non-root user
|
||||
RUN addgroup -g 1001 -S nodejs && \
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue