瀏覽代碼

Merge pull request #2731 from atoff/feat/npmrc

feat: Mount .npmrc into workspace home
Shao Yu-Lung (Allen) 4 年之前
父節點
當前提交
123d818777
共有 3 個文件被更改,包括 5 次插入0 次删除
  1. 1 0
      DOCUMENTATION/content/documentation/index.md
  2. 0 0
      workspace/.npmrc
  3. 4 0
      workspace/Dockerfile

+ 1 - 0
DOCUMENTATION/content/documentation/index.md

@@ -1907,6 +1907,7 @@ To install NVM and NodeJS in the Workspace container
 
 3 - Re-build the container `docker-compose build workspace`
 
+A `.npmrc` file is included in the `workspace` folder if you need to utilise this globally. This is copied automatically into the root and laradock user's folders on build.
 
 
 <br>

+ 0 - 0
workspace/.npmrc


+ 4 - 0
workspace/Dockerfile

@@ -770,6 +770,10 @@ RUN if [ ${NPM_REGISTRY} ]; then \
     . ~/.bashrc && npm config set registry ${NPM_REGISTRY} \
 ;fi
 
+# Mount .npmrc into home folder
+COPY ./.npmrc /root/.npmrc
+COPY ./.npmrc /home/laradock/.npmrc
+
 
 ###########################################################################
 # PNPM: