Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
H
hrsystem
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
hrsystem
Commits
ba6d8df7
Commit
ba6d8df7
authored
Apr 02, 2026
by
Administrator
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update frontend/Dockerfile via Son of Anton
parent
aea0a394
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
23 additions
and
24 deletions
+23
-24
Dockerfile
frontend/Dockerfile
+23
-24
No files found.
frontend/Dockerfile
View file @
ba6d8df7
# Stage 1: Dependencies
FROM
node:20-alpine AS deps
WORKDIR
/app
COPY
package.json package-lock.json* ./
RUN
npm ci
--legacy-peer-deps
# Stage 2: Build
FROM
node:20-alpine AS builder
WORKDIR
/app
COPY
--from=deps /app/node_modules ./node_modules
COPY
. .
ENV
NEXT_TELEMETRY_DISABLED=1
RUN
apk add
--no-cache
libc6-compat
WORKDIR
/build
# Copy shared types
COPY
shared/ ./shared/
# Copy frontend
COPY
frontend/package*.json ./frontend/
WORKDIR
/build/frontend
RUN
npm
install
--legacy-peer-deps
COPY
frontend/ ./
# Build Next.js
ENV
NEXT_TELEMETRY_DISABLED=1
RUN
npm run build
# Stage 3: Production
FROM
node:20-alpine AS runner
# --- Production ---
FROM
node:20-alpine
RUN
apk add
--no-cache
libc6-compat
WORKDIR
/app
ENV
NODE_ENV=production
ENV
NEXT_TELEMETRY_DISABLED=1
RUN
addgroup
--system
--gid
1001 nodejs
&&
\
adduser
--system
--uid
1001 nextjs
COPY
--from=builder /app/public ./public
COPY
--from=builder --chown=nextjs:nodejs /app/.next/standalone ./
COPY
--from=builder --chown=nextjs:nodejs /app/.next/static ./.next/static
USER
nextjs
COPY
--from=builder /build/frontend/.next/standalone ./
COPY
--from=builder /build/frontend/.next/static ./.next/static
COPY
--from=builder /build/frontend/public ./public
EXPOSE
3000
ENV
PORT=3000
ENV
HOSTNAME="0.0.0.0"
CMD
["node", "server.js"]
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment