Files
plex-playlist/Dockerfile.frontend
copilotcoder f71025ee1c
Some checks failed
CICD / Build and Push CICD Images (push) Successful in 12m19s
CICD / Build CICD Image Failure Postmortem (push) Has been skipped
CICD / Source Checks (push) Successful in 3m42s
CICD / Source Lanes Failure Postmortem (push) Has been skipped
CICD / Dependency Audits (Informational) (push) Successful in 8m20s
CICD / CICD Tests Complete (push) Successful in 5s
CICD / Build Tester Images (push) Successful in 2m54s
CICD / Build Release Images (push) Successful in 11m7s
CICD / Production Image Failures Postmortem (push) Has been skipped
CICD / Production Images Complete (push) Successful in 4s
CICD / Runtime Black-Box Integration Tests (push) Successful in 1m17s
CICD / Integration Tests Failure Postmortem (push) Has been skipped
CICD / End-to-End Tests (push) Failing after 5m14s
CICD / Promote Staging Images To Release (push) Has been skipped
CICD / E2E Tests Failure Postmortem (push) Successful in 9s
fix(frontend-image): use repo-pinned yarn for immutable install
2026-07-22 14:26:11 -04:00

39 lines
791 B
Docker

# Frontend Dockerfile for Vue/Vite TypeScript project
FROM node:24-alpine AS deps
WORKDIR /app
COPY frontend/package.json frontend/yarn.lock frontend/.yarnrc.yml ./
RUN set -eux; \
retry() { \
attempts="$1"; shift; \
n=1; \
while [ "$n" -le "$attempts" ]; do \
if "$@"; then \
return 0; \
fi; \
if [ "$n" -lt "$attempts" ]; then \
sleep "$((3 * n))"; \
fi; \
n=$((n + 1)); \
done; \
return 1; \
}; \
corepack enable; \
retry 5 corepack prepare yarn@4.17.1 --activate; \
retry 5 yarn install --immutable
FROM deps AS build
COPY frontend/ .
RUN yarn build
FROM nginx:alpine AS production
COPY --from=build /app/dist /usr/share/nginx/html
COPY frontend/nginx.conf /etc/nginx/nginx.conf
EXPOSE 80
CMD ["nginx", "-g", "daemon off;"]