Blame
|
1 | # Linux 远程开发环境配置 |
||||||
|
2 | |||||||
| 3 | ::: info |
|||||||
| 4 | 为了利用阿里内网加速,下面用到了内网域名,公网无法使用 |
|||||||
| 5 | 如在公网使用,请将 http://mirrors.cloud.aliyuncs.com 替换成 https://mirrors.aliyun.com |
|||||||
| 6 | ::: |
|||||||
| 7 | ||||||||
|
8 | ## 安装 oh-my-bash |
||||||
| 9 | ||||||||
| 10 | ```sh |
|||||||
|
11 | bash -c "$(curl -fsSL https://raw.githubusercontent.com/ohmybash/oh-my-bash/master/tools/install.sh)" |
||||||
|
12 | ``` |
||||||
| 13 | ||||||||
|
14 | ## 安装 git unzip |
||||||
| 15 | ||||||||
| 16 | ```sh |
|||||||
| 17 | apt update |
|||||||
|
18 | apt install -y git unzip |
||||||
|
19 | ``` |
||||||
| 20 | ||||||||
| 21 | ## nodejs 安装 |
|||||||
| 22 | ||||||||
| 23 | ```sh |
|||||||
| 24 | curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.7/install.sh | bash |
|||||||
| 25 | ``` |
|||||||
| 26 | ||||||||
| 27 | ### node 代理 |
|||||||
| 28 | ||||||||
| 29 | ```sh |
|||||||
| 30 | export NVM_NODEJS_ORG_MIRROR=http://mirrors.cloud.aliyuncs.com/nodejs-release |
|||||||
| 31 | ``` |
|||||||
| 32 | ||||||||
|
33 | ```sh |
||||||
| 34 | echo 'export NVM_NODEJS_ORG_MIRROR=http://mirrors.cloud.aliyuncs.com/nodejs-release' >> /root/.bashrc |
|||||||
| 35 | ``` |
|||||||
| 36 | ||||||||
| 37 | ``` |
|||||||
| 38 | nvm install 14.21.3 |
|||||||
| 39 | ``` |
|||||||
| 40 | ||||||||
|
41 | ### npm 代理 |
||||||
| 42 | ||||||||
| 43 | ```sh |
|||||||
| 44 | npm config set registry https://registry.npmmirror.com |
|||||||
| 45 | ``` |
|||||||
| 46 | ||||||||
| 47 | ## docker 安装 |
|||||||
| 48 | ||||||||
| 49 | ```sh |
|||||||
| 50 | export DOWNLOAD_URL="http://mirrors.cloud.aliyuncs.com/docker-ce/" |
|||||||
| 51 | curl -fsSL https://get.docker.com/ | sudo -E sh |
|||||||
| 52 | ``` |
|||||||