chore:修复部署教程配置信息中的一个死链 #10
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: 构建文档Docker镜像 | |
on: | |
push: | |
branches: | |
- main | |
permissions: | |
contents: write | |
jobs: | |
build-docker-image: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- name: 设置 Node.js | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 18 | |
- name: 安装 pnpm | |
run: | | |
npm install -g pnpm | |
- name: 安装依赖 | |
run: | |
pnpm install | |
- name: 构建文档 | |
env: | |
NODE_OPTIONS: --max_old_space_size=8192 | |
run: | | |
pnpm run docs:build | |
ls -R | |
- name: Build image | |
run: | | |
docker build -t ${{ secrets.DOCKER_ACCOUNT }}/qchatgpt-wiki:latest . | |
- name: Publish image | |
run: | | |
docker login -u ${{ secrets.DOCKER_ACCOUNT }} -p ${{ secrets.DOCKER_PWD}} | |
docker push ${{ secrets.DOCKER_ACCOUNT }}/qchatgpt-wiki:latest |