Unable to build docker image on a clean environment
[The CI](https://gitlab.mim-libre.fr/alphabet/laboite-blog-front/-/jobs/26902) and my test machine can't build the docker image. When executing `docker build .` I got the following error: ``` > yarn css-build && sapper build --legacy yarn run v1.22.17 warning package.json: No license field $ node-sass --omit-source-map-url src/utils/theme/index.scss src/utils/theme/index.css /bin/sh: node-sass: not found error Command failed with exit code 127. ``` <details><summary>full docker build log</summary> ``` $ docker build . Sending build context to Docker daemon 2.358MB Step 1/13 : FROM hub.eole.education/proxyhub/library/node:12-alpine ---> 8a6e486e9817 Step 2/13 : ENV PORT=4000 ---> Using cache ---> 6a1179cad5e4 Step 3/13 : ENV NODE_ENV=production ---> Using cache ---> f212cc3e585b Step 4/13 : run apk add git gcc ---> Using cache ---> 08f47e986f28 Step 5/13 : WORKDIR /app ---> Using cache ---> cff59db2fe27 Step 6/13 : COPY . . ---> f59346997b6b Step 7/13 : RUN npm install --production ---> Running in 0d0de83d3eed npm WARN deprecated request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142 npm WARN deprecated har-validator@5.1.5: this library is no longer supported npm WARN deprecated uuid@3.4.0: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details. > core-js@3.20.3 postinstall /app/node_modules/core-js > node -e "try{require('./postinstall')}catch(e){}" Thank you for using core-js ( https://github.com/zloirock/core-js ) for polyfilling JavaScript standard library! The project needs your help! Please consider supporting of core-js: > https://opencollective.com/core-js > https://patreon.com/zloirock > https://paypal.me/zloirock > bitcoin: bc1qlea7544qtsmj2rayg0lthvza9fau63ux0fstcz Also, the author of core-js ( https://github.com/zloirock ) is looking for a good job -) npm notice created a lockfile as package-lock.json. You should commit this file. npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@~2.3.2 (node_modules/rollup/node_modules/fsevents): npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@2.3.2: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"}) npm WARN rollup-plugin-postcss@4.0.2 requires a peer of postcss@8.x but none is installed. You must install peer dependencies yourself. npm WARN cssnano@5.0.15 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-modules@4.3.0 requires a peer of postcss@^8.0.0 but none is installed. You must install peer dependencies yourself. npm WARN cssnano-preset-default@5.1.10 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN css-declaration-sorter@6.1.4 requires a peer of postcss@^8.0.9 but none is installed. You must install peer dependencies yourself. npm WARN cssnano-utils@3.0.0 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-calc@8.2.2 requires a peer of postcss@^8.2.2 but none is installed. You must install peer dependencies yourself. npm WARN postcss-colormin@5.2.3 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-convert-values@5.0.2 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-discard-duplicates@5.0.1 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-discard-comments@5.0.1 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-discard-empty@5.0.1 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-discard-overridden@5.0.2 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-merge-longhand@5.0.4 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-minify-font-values@5.0.2 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-merge-rules@5.0.4 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-minify-gradients@5.0.4 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-minify-params@5.0.3 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-minify-selectors@5.1.1 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-normalize-charset@5.0.1 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-normalize-display-values@5.0.2 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-normalize-positions@5.0.2 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-normalize-repeat-style@5.0.2 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-normalize-string@5.0.2 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-normalize-timing-functions@5.0.2 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-normalize-unicode@5.0.2 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-normalize-url@5.0.4 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-normalize-whitespace@5.0.2 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-ordered-values@5.0.3 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-reduce-initial@5.0.2 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-reduce-transforms@5.0.2 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-svgo@5.0.3 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-unique-selectors@5.0.2 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN stylehacks@5.0.1 requires a peer of postcss@^8.2.15 but none is installed. You must install peer dependencies yourself. npm WARN postcss-modules-extract-imports@3.0.0 requires a peer of postcss@^8.1.0 but none is installed. You must install peer dependencies yourself. npm WARN postcss-modules-local-by-default@4.0.0 requires a peer of postcss@^8.1.0 but none is installed. You must install peer dependencies yourself. npm WARN postcss-modules-scope@3.0.0 requires a peer of postcss@^8.1.0 but none is installed. You must install peer dependencies yourself. npm WARN postcss-modules-values@4.0.0 requires a peer of postcss@^8.1.0 but none is installed. You must install peer dependencies yourself. npm WARN icss-utils@5.1.0 requires a peer of postcss@^8.1.0 but none is installed. You must install peer dependencies yourself. npm WARN laboite-blog-front@1.1.1 No repository field. npm WARN laboite-blog-front@1.1.1 No license field. added 134 packages from 1040 contributors and audited 671 packages in 38.039s 31 packages are looking for funding run `npm fund` for details found 6 moderate severity vulnerabilities run `npm audit fix` to fix them, or `npm audit` for details Removing intermediate container 0d0de83d3eed ---> 8c934ebb21cf Step 8/13 : RUN npm rebuild node-sass ---> Running in f354c7d1c133 Removing intermediate container f354c7d1c133 ---> 1a0b76038446 Step 9/13 : RUN npm install --save ---> Running in 2ac2a46a60e0 npm WARN laboite-blog-front@1.1.1 No repository field. npm WARN laboite-blog-front@1.1.1 No license field. audited 671 packages in 3.691s 31 packages are looking for funding run `npm fund` for details found 6 moderate severity vulnerabilities run `npm audit fix` to fix them, or `npm audit` for details Removing intermediate container 2ac2a46a60e0 ---> 65420593a0e0 Step 10/13 : RUN npm run build ---> Running in ee9cbc18067c > laboite-blog-front@1.1.1 build /app > yarn css-build && sapper build --legacy yarn run v1.22.17 warning package.json: No license field $ node-sass --omit-source-map-url src/utils/theme/index.scss src/utils/theme/index.css /bin/sh: node-sass: not found error Command failed with exit code 127. info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command. npm ERR! code ELIFECYCLE npm ERR! syscall spawn npm ERR! file sh npm ERR! errno ENOENT npm ERR! laboite-blog-front@1.1.1 build: `yarn css-build && sapper build --legacy` npm ERR! spawn ENOENT npm ERR! npm ERR! Failed at the laboite-blog-front@1.1.1 build script. npm ERR! This is probably not a problem with npm. There is likely additional logging output above. npm ERR! A complete log of this run can be found in: npm ERR! /root/.npm/_logs/2022-01-21T15_29_04_302Z-debug.log The command '/bin/sh -c npm run build' returned a non-zero code: 1 ``` </details>
issue