Skip to content

Commit 61676d5

Browse files
committed
remove unused files and change to personal style
1 parent 03d1590 commit 61676d5

File tree

3,133 files changed

+557
-158553
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

3,133 files changed

+557
-158553
lines changed

.github/workflows/build-image.yaml

+43
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
name: Build and Push Multi-Arch Docker Image
2+
3+
on:
4+
push:
5+
tags:
6+
- "*"
7+
8+
permissions:
9+
packages: write
10+
11+
jobs:
12+
build-and-push:
13+
runs-on: ubuntu-latest
14+
15+
steps:
16+
- name: Checkout Code
17+
uses: actions/checkout@v3
18+
19+
- name: Set up QEMU
20+
uses: docker/setup-qemu-action@v2
21+
with:
22+
platforms: linux/arm64, linux/amd64
23+
24+
- name: Set up Docker Buildx
25+
uses: docker/setup-buildx-action@v2
26+
27+
- name: Login to GitHub Container Registry
28+
uses: docker/login-action@v2
29+
with:
30+
registry: ghcr.io
31+
username: ${{ github.actor }}
32+
password: ${{ secrets.GITHUB_TOKEN }}
33+
34+
- name: Build and Push Docker Image
35+
uses: docker/build-push-action@v5
36+
with:
37+
context: .
38+
file: ./Dockerfile
39+
push: true
40+
tags: |
41+
ghcr.io/${{ github.repository }}/sophdoc:${{ github.ref_name }}
42+
ghcr.io/${{ github.repository }}/sophdoc:latest
43+
platforms: linux/amd64, linux/arm64

Dockerfile

+34
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
# 构建阶段
2+
FROM python:3.12-slim AS builder
3+
4+
WORKDIR /docs
5+
6+
# 安装 mkdocs 和依赖
7+
RUN pip install --no-cache-dir \
8+
mkdocs \
9+
mkdocs-material \
10+
mkdocs-minify-plugin \
11+
pymdown-extensions \
12+
mkdocs-swagger-ui-tag \
13+
mkdocs-static-i18n
14+
15+
# 复制项目文件
16+
COPY . /docs
17+
18+
# 构建静态文件
19+
RUN mkdocs build -f mkdocs.yml
20+
21+
# Nginx 阶段
22+
FROM nginx:alpine
23+
24+
# 复制 Nginx 配置文件
25+
COPY nginx.conf /etc/nginx/conf.d/default.conf
26+
27+
# 从构建阶段复制构建好的静态文件
28+
COPY --from=builder /docs/site /usr/share/nginx/html
29+
30+
# 暴露端口
31+
EXPOSE 8000
32+
33+
# Nginx 使用 daemon off 模式运行
34+
CMD ["nginx", "-g", "daemon off;"]

docs/en/docs/baize/developer/dataset/create-use-delete.md

-89
This file was deleted.

docs/en/docs/baize/developer/dataset/environments.md

-95
This file was deleted.

docs/en/docs/baize/developer/index.md

-8
This file was deleted.

docs/en/docs/baize/developer/inference/models.md

-55
This file was deleted.

0 commit comments

Comments
 (0)