From 176bfa0ea0d021ed1a825af4bb2d06645fd5df03 Mon Sep 17 00:00:00 2001 From: Leon Xu <6479451-leonxu260@users.noreply.gitlab.com> Date: Thu, 26 Aug 2021 23:47:29 -0700 Subject: [PATCH] doc: install nodejs and curl before execution of npm --- README.md | 27 +++++++++++---------------- 1 file changed, 11 insertions(+), 16 deletions(-) diff --git a/README.md b/README.md index a8b8c11..a3ae738 100644 --- a/README.md +++ b/README.md @@ -44,22 +44,17 @@ If I want GitLab CI/CD to deploy my website each time that I push to GitLab, I c
```yaml -build website: - stage: build - # Using the latest of ubuntu image - image: ubuntu:latest - - cache: - paths: - - node_modules/ # Node modules and dependencies - - before_script: - - apt-get update -qy # Check for update - - apt-get install -y lftp # Install lftp - - npm install -g hexo-cli # Install Hexo itself - - npm install # Install Hexo modules and dependencies - - npm install hexo-renderer-pug # Install Butterfly pug - - npm install hexo-renderer-stylus # Install stylus renderer +image: ubuntu:latest +before_script: + - apt update -qy # Check for update + - apt install -y lftp # Install lftp + - apt install curl # Install curl + - curl -fsSL https://deb.nodesource.com/setup_current.x | sudo -E bash - + - apt install nodejs # Install NodeJS + - npm install -g hexo-cli # Install Hexo itself + - npm install # Install Hexo modules and dependencies + - npm install hexo-renderer-pug # Install Butterfly pug + - npm install hexo-renderer-stylus # Install stylus renderer deploy via lftp: stage: deploy