feat: add server deployment, desktop builds, and CI/CD pipeline
- Add Dockerfile with adapter-node for server deployment - Add Kubernetes deployment and ingress manifests - Add GitHub Actions workflow (server build, desktop builds, K8s deploy) - Electron now loads hosted URL (https://optima.osdci.net) in production - Add macOS DMG maker and make:macos script - Switch to static imports in lib/index.ts - Add .dockerignore
This commit is contained in:
+29
@@ -0,0 +1,29 @@
|
||||
FROM node:22-alpine AS base
|
||||
|
||||
RUN corepack enable && corepack prepare pnpm@latest --activate
|
||||
WORKDIR /app
|
||||
|
||||
# Install dependencies
|
||||
COPY package.json pnpm-lock.yaml ./
|
||||
COPY patches ./patches
|
||||
RUN pnpm install --frozen-lockfile
|
||||
|
||||
# Build the SvelteKit app with adapter-node
|
||||
COPY . .
|
||||
RUN pnpm run build:server
|
||||
|
||||
# Production image
|
||||
FROM node:22-alpine AS production
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
COPY --from=base /app/build ./build
|
||||
COPY --from=base /app/package.json ./
|
||||
|
||||
ENV NODE_ENV=production
|
||||
ENV PORT=3000
|
||||
ENV ORIGIN=https://optima.osdci.net
|
||||
|
||||
EXPOSE 3000
|
||||
|
||||
CMD ["node", "build/index.js"]
|
||||
Reference in New Issue
Block a user