| # 使用 Node.js 环境 | |
| FROM node:22 | |
| # 更新包管理器并安装必要的软件 | |
| RUN apt-get update && apt-get install -y \ | |
| python3 \ | |
| git \ | |
| build-essential \ | |
| g++ \ | |
| libx11-dev \ | |
| libxkbfile-dev \ | |
| libsecret-1-dev \ | |
| libkrb5-dev \ | |
| python-is-python3 \ | |
| && apt-get clean && rm -rf /var/lib/apt/lists/* | |
| # Clone VS Code | |
| RUN git clone https://github.com/microsoft/vscode | |
| # cd & install | |
| RUN cd vscode ; pwd ; npm install | |
| # 开启 Code Server | |
| EXPOSE 9888 | |
| RUN "/vscode/script/code-server.sh --launch" |