File tree Expand file tree Collapse file tree 3 files changed +34
-14
lines changed Expand file tree Collapse file tree 3 files changed +34
-14
lines changed Original file line number Diff line number Diff line change @@ -27,24 +27,30 @@ jobs:
27
27
runs-on : ubuntu-latest
28
28
steps :
29
29
- uses : actions/checkout@v4
30
- - uses : actions/setup-node@v4
31
- with :
32
- node-version : ' 18'
33
-
34
- - name : Install dependencies
30
+ - name : Build docusaurus container
35
31
run : |
36
32
cd docusaurus/
37
- yarn install --frozen-lockfile
38
-
39
- - name : Build and test Docusaurus
33
+ docker compose -f docker-compose.yml build dev
34
+ - name : Start docusaurus container
40
35
run : |
41
36
cd docusaurus/
42
- yarn test
43
-
44
- - name : Verify build output
37
+ docker compose -f docker-compose.yml up -d dev
38
+ - name : Wait for docusaurus to start
45
39
run : |
46
- cd docusaurus/
47
- test -d build && echo "✅ Build successful"
40
+ echo "Waiting for Docusaurus to start..."
41
+ sleep 60
42
+ - name : Check running containers
43
+ run : |
44
+ echo "Checking running containers..."
45
+ docker ps -a
46
+ - name : Check Docusaurus logs
47
+ run : |
48
+ echo "Checking Docusaurus logs..."
49
+ docker logs docusaurus_local
50
+ - name : Check Docusaurus health
51
+ run : |
52
+ echo "Checking Docusaurus health..."
53
+ curl -f http://localhost:3000 > /dev/null || exit 1
48
54
49
55
markdown-lint :
50
56
name : Markdown Format Check
Original file line number Diff line number Diff line change @@ -20,8 +20,23 @@ FROM node:22-slim AS base
20
20
ENV FORCE_COLOR=0
21
21
RUN corepack enable
22
22
WORKDIR /opt/docusaurus
23
+
24
+ # Documentation contents
25
+ # The docs directory is overwritten by compose file
26
+ COPY docs docs
27
+ COPY src src
28
+ COPY static static
29
+ COPY versioned_docs versioned_docs
30
+ COPY versioned_sidebars versioned_sidebars
31
+
32
+ # Configuration files
33
+ COPY docusaurus.config.js .
23
34
COPY package.json .
24
35
COPY package-lock.json* .
36
+ COPY sidebars.js .
37
+ COPY sidebars.json .
38
+ COPY test.js .
39
+ COPY versions.json .
25
40
26
41
# ==================================================================
27
42
# Local deployment
Original file line number Diff line number Diff line change @@ -10,7 +10,6 @@ services:
10
10
ports :
11
11
- " 3000:3000"
12
12
volumes :
13
- - .:/opt/docusaurus
14
13
- ./../readmes:/opt/docusaurus/docs
15
14
environment :
16
15
- NODE_ENV=development
You can’t perform that action at this time.
0 commit comments