From 7439f7a54a56cdb05a69cceb740602463d363e8f Mon Sep 17 00:00:00 2001 From: Vadim Chervoniak Date: Mon, 27 Jan 2025 02:51:30 +0200 Subject: [PATCH] Update static-deploy.md Summary The previous .gitlab-ci.yml used node:16.5.0, which caused deployment to fail during the build step due to compatibility issues with vite build. This PR updates the Node.js version to node:18.16.0, resolving the issue and ensuring the pipeline runs successfully. --- docs/guide/static-deploy.md | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/docs/guide/static-deploy.md b/docs/guide/static-deploy.md index 7664bc8ceaeff4..60d08b17eb1cf3 100644 --- a/docs/guide/static-deploy.md +++ b/docs/guide/static-deploy.md @@ -128,20 +128,19 @@ Now the `preview` command will launch the server at `http://localhost:8080`. 2. Create a file called `.gitlab-ci.yml` in the root of your project with the content below. This will build and deploy your site whenever you make changes to your content: ```yaml [.gitlab-ci.yml] - image: node:16.5.0 + image: node:18.16.0 + pages: stage: deploy cache: - key: - files: - - package-lock.json - prefix: npm + key: npm-cache paths: - node_modules/ script: - npm install - npm run build - - cp -a dist/. public/ + - mkdir -p public + - cp -r dist/* public artifacts: paths: - public