diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 0000000..7331841 --- /dev/null +++ b/.dockerignore @@ -0,0 +1,3 @@ +node_modules +.next +*.log \ No newline at end of file diff --git a/.eslintrc.json b/.eslintrc.json deleted file mode 100644 index 3722418..0000000 --- a/.eslintrc.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "extends": ["next/core-web-vitals", "next/typescript"] -} diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..b0d57d3 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,31 @@ +FROM node:18-alpine AS builder + +RUN apk add --no-cache yarn + +WORKDIR /app + +COPY package.json yarn.lock ./ + +RUN yarn install --frozen-lockfile + +COPY . . + +RUN yarn build + +FROM node:18-alpine AS runner + +WORKDIR /app + +ENV NODE_ENV production + +COPY --from=builder /app/public ./public +COPY --from=builder /app/.next/standalone ./ +COPY --from=builder /app/.next/static ./.next/static +COPY --from=builder /app/package.json ./package.json +COPY --from=builder /app/yarn.lock ./yarn.lock + +RUN yarn install --production --frozen-lockfile + +EXPOSE 3000 + +CMD ["node", "server.js"] \ No newline at end of file diff --git a/eslint.config.mjs b/eslint.config.mjs new file mode 100644 index 0000000..0dc0afd --- /dev/null +++ b/eslint.config.mjs @@ -0,0 +1,19 @@ +import { FlatCompat } from '@eslint/eslintrc' + +const compat = new FlatCompat({ + baseDirectory: import.meta.dirname, +}) + +// WHY TF I INSTALLED ESLINT +const eslintConfig = [ + ...compat.config({ + extends: ['next'], + rules: { + 'react/no-unescaped-entities': 'off', + '@next/next/no-page-custom-font': 'off', + '@typescript-eslint/no-unused-vars': 'off' + }, + }), +] + +export default eslintConfig \ No newline at end of file diff --git a/src/app/not-found.tsx b/src/app/not-found.tsx index ebe6c27..6821bd6 100644 --- a/src/app/not-found.tsx +++ b/src/app/not-found.tsx @@ -12,7 +12,7 @@ export default function NotFound() {

404

- Oh you lost, you know there's nothing here... + Oh you lost, you know there's nothing here...
diff --git a/tsconfig.json b/tsconfig.json index 7b28589..903c2b0 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -6,6 +6,7 @@ "strict": true, "noEmit": true, "esModuleInterop": true, + "target": "es2015", "module": "esnext", "moduleResolution": "bundler", "resolveJsonModule": true,