feat/better-deploy #2
@ -22,8 +22,6 @@ export default {
|
|||||||
bodyAttributes: {
|
bodyAttributes: {
|
||||||
class: "flex min-h-full bg-white dark:bg-slate-900",
|
class: "flex min-h-full bg-white dark:bg-slate-900",
|
||||||
},
|
},
|
||||||
|
|
||||||
prerender: true,
|
|
||||||
prefetchStaticAssets: "hover",
|
prefetchStaticAssets: "hover",
|
||||||
|
|
||||||
extends: vikeReact,
|
extends: vikeReact,
|
||||||
|
|||||||
@ -1,6 +0,0 @@
|
|||||||
import { docsService } from "@/services/DocsService";
|
|
||||||
|
|
||||||
export async function onBeforePrerenderStart() {
|
|
||||||
const allDocumentations = await docsService.getUrls("certifications");
|
|
||||||
return allDocumentations;
|
|
||||||
}
|
|
||||||
@ -1,6 +0,0 @@
|
|||||||
import { docsService } from "@/services/DocsService";
|
|
||||||
|
|
||||||
export async function onBeforePrerenderStart() {
|
|
||||||
const allDocumentations = await docsService.getUrls("docs");
|
|
||||||
return allDocumentations;
|
|
||||||
}
|
|
||||||
11
compose-prod.yml
Normal file
11
compose-prod.yml
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
services:
|
||||||
|
memento-prod:
|
||||||
|
container_name: memento-prod
|
||||||
|
build:
|
||||||
|
context: .
|
||||||
|
dockerfile: production.Dockerfile
|
||||||
|
env_file:
|
||||||
|
- .env
|
||||||
|
ports:
|
||||||
|
- "${PORT}:${PORT}"
|
||||||
|
restart: unless-stopped
|
||||||
@ -12,4 +12,4 @@ RUN chmod -R 775 /app
|
|||||||
EXPOSE 3000
|
EXPOSE 3000
|
||||||
|
|
||||||
ENTRYPOINT [ "pnpm" ]
|
ENTRYPOINT [ "pnpm" ]
|
||||||
CMD [ "sh", "-c", "if [ \"$NODE_ENV\" = 'production' ]; then pnpm preview; else pnpm dev; fi" ]
|
CMD [ "pnpm", "dev" ]
|
||||||
17
production.Dockerfile
Normal file
17
production.Dockerfile
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
FROM node:22-alpine
|
||||||
|
|
||||||
|
WORKDIR /app
|
||||||
|
|
||||||
|
RUN npm install -g pnpm
|
||||||
|
|
||||||
|
COPY ./app/package.json ./app/pnpm-lock.yaml ./
|
||||||
|
|
||||||
|
RUN pnpm install --frozen-lockfile --production
|
||||||
|
|
||||||
|
COPY ./app /app
|
||||||
|
|
||||||
|
RUN pnpm build
|
||||||
|
|
||||||
|
EXPOSE 3000
|
||||||
|
|
||||||
|
CMD [ "pnpm", "preview" ]
|
||||||
Loading…
Reference in New Issue
Block a user