feat(ci): add automated Lighthouse audit pipeline
This commit is contained in:
16
Dockerfile
16
Dockerfile
@@ -1,7 +1,8 @@
|
||||
ARG NODE_VERSION
|
||||
ARG CADDY_VERSION
|
||||
|
||||
# --- BUILD ---
|
||||
FROM node:24-alpine AS build
|
||||
FROM node:${NODE_VERSION}-alpine AS build
|
||||
RUN corepack enable && corepack prepare pnpm@latest --activate
|
||||
|
||||
ENV ASTRO_TELEMETRY_DISABLED=1
|
||||
@@ -10,10 +11,19 @@ WORKDIR /app
|
||||
|
||||
# Copy depedencies
|
||||
COPY package.json pnpm-lock.yaml ./
|
||||
RUN pnpm install --frozen-lockfile
|
||||
|
||||
# Copy all and build
|
||||
# Install pnpm with cache
|
||||
RUN --mount=type=cache,id=pnpm,target=/pnpm/store \
|
||||
PNPM_HOME="/pnpm" pnpm install --frozen-lockfile
|
||||
|
||||
# Copy all
|
||||
COPY . .
|
||||
|
||||
# Check files
|
||||
RUN pnpm run lint
|
||||
RUN pnpm run check
|
||||
|
||||
# Build
|
||||
RUN pnpm build
|
||||
|
||||
# --- DEPLOY ---
|
||||
|
||||
Reference in New Issue
Block a user