diff --git a/Dockerfile b/Dockerfile index 26f43d6..fe2be79 100644 --- a/Dockerfile +++ b/Dockerfile @@ -14,7 +14,9 @@ ENV PATH="$PNPM_HOME:$PATH" # Install required system packages and pnpm, then clean up the apt cache for a smaller image # ca-certificates: enables TLS/SSL for securely fetching dependencies and calling HTTPS services # --no-install-recommends keeps the image minimal -RUN apt-get update -qq && apt-get install --no-install-recommends -y ca-certificates && rm -rf /var/lib/apt/lists/* +RUN apt-get update -qq && \ + apt-get install --no-install-recommends -y ca-certificates && \ + rm -rf /var/lib/apt/lists/* # Pin pnpm version for reproducible builds RUN npm install -g pnpm@10 @@ -24,13 +26,13 @@ RUN npm install -g pnpm@10 WORKDIR /app # Copy just the dependency files first, for more efficient layer caching -COPY package.json pnpm-lock.yaml ./ +COPY package.json package-lock.json ./ # Install dependencies using pnpm -# --frozen-lockfile ensures we use exact versions from pnpm-lock.yaml for reproducible builds +# --frozen-lockfile ensures we use exact versions from package-lock.json for reproducible builds RUN pnpm install --frozen-lockfile -# Copy all remaining pplication files into the container +# Copy all remaining application files into the container # This includes source code, configuration files, and dependency specifications # (Excludes files specified in .dockerignore) COPY . . @@ -60,7 +62,8 @@ RUN pnpm download-files # Switch back to root to remove dev dependencies and finalize setup USER root -RUN pnpm prune --prod && chown -R appuser:appuser /app +RUN pnpm prune --prod +RUN chown -R appuser:appuser /app USER appuser # Set Node.js to production mode diff --git a/eslint.config.ts b/eslint.config.ts index 2c01edd..31ec5f2 100644 --- a/eslint.config.ts +++ b/eslint.config.ts @@ -1,9 +1,14 @@ -import js from "@eslint/js"; -import globals from "globals"; -import tseslint from "typescript-eslint"; -import { defineConfig } from "eslint/config"; +import js from '@eslint/js'; +import { defineConfig } from 'eslint/config'; +import globals from 'globals'; +import tseslint from 'typescript-eslint'; export default defineConfig([ - { files: ["**/*.{js,mjs,cjs,ts,mts,cts}"], plugins: { js }, extends: ["js/recommended"], languageOptions: { globals: globals.node } }, + { + files: ['**/*.{js,mjs,cjs,ts,mts,cts}'], + plugins: { js }, + extends: ['js/recommended'], + languageOptions: { globals: globals.node }, + }, tseslint.configs.recommended, ]);