File tree Expand file tree Collapse file tree 3 files changed +42
-0
lines changed Expand file tree Collapse file tree 3 files changed +42
-0
lines changed Original file line number Diff line number Diff line change @@ -25,6 +25,9 @@ This repository contains Dockerfiles and related resources for building and runn
25
25
- ` lucide-icon-docs/ `
26
26
- Contains the Dockerfile for building the Lucide Icon documentation site.
27
27
- GitHub Repository: [ Lucide Icons] ( https://github.com/lucide-icons/lucide )
28
+ - ` vitejs/ `
29
+ - Contains the Dockerfile for building the Vite Chinese documentation site.
30
+ - GitHub Repository: [ Vite Chinese Docs] ( https://github.com/vitejs/docs-cn )
28
31
29
32
## Usage
30
33
Original file line number Diff line number Diff line change
1
+ FROM node:22-alpine AS builder
2
+
3
+ RUN apk add --no-cache git
4
+
5
+ WORKDIR /app
6
+
7
+ RUN git clone -b v6.0.0 https://github.com/vitejs/docs-cn.git
8
+
9
+ WORKDIR /app/docs-cn
10
+
11
+ RUN npm install -g pnpm
12
+
13
+ RUN pnpm install
14
+
15
+ RUN pnpm run build
16
+
17
+ FROM nginx:alpine
18
+
19
+ COPY --from=builder /app/docs-cn/.vitepress/dist /usr/share/nginx/html
20
+
21
+ EXPOSE 80
22
+
23
+ CMD ["nginx" , "-g" , "daemon off;" ]
Original file line number Diff line number Diff line change
1
+ server {
2
+ listen 80 ;
3
+ server_name localhost;
4
+ root /usr/share/nginx/html;
5
+ index index.html;
6
+
7
+ location / {
8
+ try_files $uri $uri / /index.html;
9
+ add_header Cache-Control "no-cache, must-revalidate" ;
10
+ }
11
+
12
+ error_page 500 502 503 504 /50x.html;
13
+ location = /50x.html {
14
+ root /usr/share/nginx/html;
15
+ }
16
+ }
You can’t perform that action at this time.
0 commit comments