Skip to content

Commit 415298f

Browse files
committed
feat: add OpenAPI sync to MCP and CLI repositories
Implement workflows to sync the OpenAPI specification to both the MCP and CLI repositories. This includes cloning the repositories, updating the openapi.json file, and committing the changes with relevant metadata. The process ensures that the OpenAPI documentation is consistently updated across multiple platforms.
1 parent ddff8b9 commit 415298f

1 file changed

Lines changed: 42 additions & 0 deletions

File tree

.github/workflows/sync-openapi-docs.yml

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,3 +68,45 @@ jobs:
6868
6969
echo "✅ OpenAPI synced to website successfully"
7070
71+
- name: Sync to MCP repository
72+
run: |
73+
git clone https://x-access-token:${{ secrets.DOCS_SYNC_TOKEN }}@github.com/dokploy/mcp.git mcp-repo
74+
75+
cd mcp-repo
76+
77+
cp -f ../openapi.json openapi.json
78+
79+
git config user.name "Dokploy Bot"
80+
git config user.email "bot@dokploy.com"
81+
82+
git add openapi.json
83+
git commit -m "chore: sync OpenAPI specification [skip ci]" \
84+
-m "Source: ${{ github.repository }}@${{ github.sha }}" \
85+
-m "Updated: $(date -u +'%Y-%m-%d %H:%M:%S UTC')" \
86+
--allow-empty
87+
88+
git push
89+
90+
echo "✅ OpenAPI synced to MCP repository successfully"
91+
92+
- name: Sync to CLI repository
93+
run: |
94+
git clone https://x-access-token:${{ secrets.DOCS_SYNC_TOKEN }}@github.com/dokploy/cli.git cli-repo
95+
96+
cd cli-repo
97+
98+
cp -f ../openapi.json openapi.json
99+
100+
git config user.name "Dokploy Bot"
101+
git config user.email "bot@dokploy.com"
102+
103+
git add openapi.json
104+
git commit -m "chore: sync OpenAPI specification [skip ci]" \
105+
-m "Source: ${{ github.repository }}@${{ github.sha }}" \
106+
-m "Updated: $(date -u +'%Y-%m-%d %H:%M:%S UTC')" \
107+
--allow-empty
108+
109+
git push
110+
111+
echo "✅ OpenAPI synced to CLI repository successfully"
112+

0 commit comments

Comments
 (0)