Skip to content

Commit 8fc74ea

Browse files
Add Orchestrator ci to run other ci (#184)
* Add Orchestrator ci to run other ci * Add Orchestrator ci to run other ci * Add Orchestrator ci to run other ci
1 parent 5994c67 commit 8fc74ea

11 files changed

Lines changed: 196 additions & 92 deletions

.github/workflows/ci-dotnet-agentframework-sampleagent.yml

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,13 @@
1+
# Copyright (c) Microsoft Corporation.
2+
# Licensed under the MIT License.
3+
14
name: CI - Build .NET Agent Framework Sample Agent
25
permissions:
36
contents: read
47

58
on:
6-
push:
7-
branches: [ main, master ]
8-
paths:
9-
- 'dotnet/agent-framework/sample-agent/**/*'
10-
pull_request:
11-
branches: [ main, master ]
12-
paths:
13-
- 'dotnet/agent-framework/sample-agent/**/*'
9+
workflow_call: # Called by orchestrator
10+
workflow_dispatch: # Manual trigger
1411

1512
jobs:
1613
dotnet-agentframework-sampleagent:

.github/workflows/ci-dotnet-semantickernel-sampleagent.yml

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,13 @@
1+
# Copyright (c) Microsoft Corporation.
2+
# Licensed under the MIT License.
3+
14
name: CI - Build .NET Semantic Kernel Sample Agent
25
permissions:
36
contents: read
47

58
on:
6-
push:
7-
branches: [ main, master ]
8-
paths:
9-
- 'dotnet/semantic-kernel/sample-agent/**/*'
10-
pull_request:
11-
branches: [ main, master ]
12-
paths:
13-
- 'dotnet/semantic-kernel/sample-agent/**/*'
9+
workflow_call: # Called by orchestrator
10+
workflow_dispatch: # Manual trigger
1411

1512
jobs:
1613
dotnet-semantickernel-sampleagent:

.github/workflows/ci-nodejs-claude-sampleagent.yml

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,8 @@
44
name: CI - Build Node.js Claude Sample Agent
55

66
on:
7-
push:
8-
branches: [ main, master ]
9-
paths:
10-
- 'nodejs/claude/sample-agent/**/*'
11-
pull_request:
12-
branches: [ main, master ]
13-
paths:
14-
- 'nodejs/claude/sample-agent/**/*'
7+
workflow_call: # Called by orchestrator
8+
workflow_dispatch: # Manual trigger
159
jobs:
1610
nodejs-claude-sampleagent:
1711
name: Node.js Claude Sample Agent

.github/workflows/ci-nodejs-langchain-sampleagent.yml

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,8 @@
44
name: CI - Build Node.js LangChain Sample Agent
55

66
on:
7-
push:
8-
branches: [ main, master ]
9-
paths:
10-
- 'nodejs/langchain/sample-agent/**/*'
11-
pull_request:
12-
branches: [ main, master ]
13-
paths:
14-
- 'nodejs/langchain/sample-agent/**/*'
7+
workflow_call: # Called by orchestrator
8+
workflow_dispatch: # Manual trigger
159
jobs:
1610
nodejs-langchain-sampleagent:
1711
name: Node.js LangChain Sample Agent

.github/workflows/ci-nodejs-openai-sampleagent.yml

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,8 @@
44
name: CI - Build Node.js OpenAI Sample Agent
55

66
on:
7-
push:
8-
branches: [ main, master ]
9-
paths:
10-
- 'nodejs/openai/sample-agent/**/*'
11-
pull_request:
12-
branches: [ main, master ]
13-
paths:
14-
- 'nodejs/openai/sample-agent/**/*'
7+
workflow_call: # Called by orchestrator
8+
workflow_dispatch: # Manual trigger
159

1610
jobs:
1711
nodejs-openai-sampleagent:

.github/workflows/ci-nodejs-vercelsdk-sampleagent.yml

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,8 @@
44
name: CI - Build Node.js Vercel SDK Sample Agent
55

66
on:
7-
push:
8-
branches: [ main, master ]
9-
paths:
10-
- 'nodejs/vercel-sdk/sample-agent/**/*'
11-
pull_request:
12-
branches: [ main, master ]
13-
paths:
14-
- 'nodejs/vercel-sdk/sample-agent/**/*'
7+
workflow_call: # Called by orchestrator
8+
workflow_dispatch: # Manual trigger
159

1610
jobs:
1711
nodejs-vercelsdk-sampleagent:
Lines changed: 158 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,158 @@
1+
# Copyright (c) Microsoft Corporation.
2+
# Licensed under the MIT License.
3+
4+
name: CI Orchestrator
5+
6+
on:
7+
push:
8+
branches: [main, master]
9+
pull_request:
10+
branches: [main, master]
11+
12+
permissions:
13+
contents: read
14+
15+
jobs:
16+
# Detect which folders have changes
17+
detect-changes:
18+
name: Detect Changes
19+
runs-on: ubuntu-latest
20+
outputs:
21+
dotnet-agentframework: ${{ steps.changes.outputs.dotnet-agentframework }}
22+
dotnet-semantickernel: ${{ steps.changes.outputs.dotnet-semantickernel }}
23+
nodejs-claude: ${{ steps.changes.outputs.nodejs-claude }}
24+
nodejs-langchain: ${{ steps.changes.outputs.nodejs-langchain }}
25+
nodejs-openai: ${{ steps.changes.outputs.nodejs-openai }}
26+
nodejs-vercelsdk: ${{ steps.changes.outputs.nodejs-vercelsdk }}
27+
python-agentframework: ${{ steps.changes.outputs.python-agentframework }}
28+
python-googleadk: ${{ steps.changes.outputs.python-googleadk }}
29+
python-openai: ${{ steps.changes.outputs.python-openai }}
30+
python-claude: ${{ steps.changes.outputs.python-claude }}
31+
steps:
32+
- name: Checkout repository
33+
uses: actions/checkout@v4
34+
35+
- name: Check for changes
36+
uses: dorny/paths-filter@v3
37+
id: changes
38+
with:
39+
filters: |
40+
dotnet-agentframework:
41+
- 'dotnet/agent-framework/**'
42+
dotnet-semantickernel:
43+
- 'dotnet/semantic-kernel/**'
44+
nodejs-claude:
45+
- 'nodejs/claude/**'
46+
nodejs-langchain:
47+
- 'nodejs/langchain/**'
48+
nodejs-openai:
49+
- 'nodejs/openai/**'
50+
nodejs-vercelsdk:
51+
- 'nodejs/vercel-sdk/**'
52+
python-agentframework:
53+
- 'python/agent-framework/**'
54+
python-googleadk:
55+
- 'python/google-adk/**'
56+
python-openai:
57+
- 'python/openai/**'
58+
python-claude:
59+
- 'python/claude/**'
60+
61+
# .NET Jobs - Call existing workflows
62+
dotnet-agentframework:
63+
name: .NET Agent Framework
64+
needs: detect-changes
65+
if: needs.detect-changes.outputs.dotnet-agentframework == 'true'
66+
uses: ./.github/workflows/ci-dotnet-agentframework-sampleagent.yml
67+
68+
dotnet-semantickernel:
69+
name: .NET Semantic Kernel
70+
needs: detect-changes
71+
if: needs.detect-changes.outputs.dotnet-semantickernel == 'true'
72+
uses: ./.github/workflows/ci-dotnet-semantickernel-sampleagent.yml
73+
74+
# Node.js Jobs - Call existing workflows
75+
nodejs-claude:
76+
name: Node.js Claude
77+
needs: detect-changes
78+
if: needs.detect-changes.outputs.nodejs-claude == 'true'
79+
uses: ./.github/workflows/ci-nodejs-claude-sampleagent.yml
80+
81+
nodejs-langchain:
82+
name: Node.js LangChain
83+
needs: detect-changes
84+
if: needs.detect-changes.outputs.nodejs-langchain == 'true'
85+
uses: ./.github/workflows/ci-nodejs-langchain-sampleagent.yml
86+
87+
nodejs-openai:
88+
name: Node.js OpenAI
89+
needs: detect-changes
90+
if: needs.detect-changes.outputs.nodejs-openai == 'true'
91+
uses: ./.github/workflows/ci-nodejs-openai-sampleagent.yml
92+
93+
nodejs-vercelsdk:
94+
name: Node.js Vercel SDK
95+
needs: detect-changes
96+
if: needs.detect-changes.outputs.nodejs-vercelsdk == 'true'
97+
uses: ./.github/workflows/ci-nodejs-vercelsdk-sampleagent.yml
98+
99+
# Python Jobs - Call existing workflows
100+
python-agentframework:
101+
name: Python Agent Framework
102+
needs: detect-changes
103+
if: needs.detect-changes.outputs.python-agentframework == 'true'
104+
uses: ./.github/workflows/ci-python-agentframework-sampleagent.yml
105+
106+
python-googleadk:
107+
name: Python Google ADK
108+
needs: detect-changes
109+
if: needs.detect-changes.outputs.python-googleadk == 'true'
110+
uses: ./.github/workflows/ci-python-googleadk-sampleagent.yml
111+
112+
python-openai:
113+
name: Python OpenAI
114+
needs: detect-changes
115+
if: needs.detect-changes.outputs.python-openai == 'true'
116+
uses: ./.github/workflows/ci-python-openai-sampleagent.yml
117+
118+
python-claude:
119+
name: Python Claude
120+
needs: detect-changes
121+
if: needs.detect-changes.outputs.python-claude == 'true'
122+
uses: ./.github/workflows/python-claude-sample.yml
123+
124+
# Final status check - ALWAYS runs and reports success
125+
# This is the ONLY check you need to mark as "Required" in branch protection
126+
ci-status:
127+
name: CI Status
128+
runs-on: ubuntu-latest
129+
needs:
130+
- detect-changes
131+
- dotnet-agentframework
132+
- dotnet-semantickernel
133+
- nodejs-claude
134+
- nodejs-langchain
135+
- nodejs-openai
136+
- nodejs-vercelsdk
137+
- python-agentframework
138+
- python-googleadk
139+
- python-openai
140+
- python-claude
141+
if: always()
142+
steps:
143+
- name: Check CI Status
144+
run: |
145+
echo "Checking CI job results..."
146+
147+
# Get all job results (including detect-changes; skipped jobs are fine, failed jobs are not)
148+
results="${{ needs.detect-changes.result }} ${{ needs.dotnet-agentframework.result }} ${{ needs.dotnet-semantickernel.result }} ${{ needs.nodejs-claude.result }} ${{ needs.nodejs-langchain.result }} ${{ needs.nodejs-openai.result }} ${{ needs.nodejs-vercelsdk.result }} ${{ needs.python-agentframework.result }} ${{ needs.python-googleadk.result }} ${{ needs.python-openai.result }} ${{ needs.python-claude.result }}"
149+
150+
echo "Job results: $results"
151+
152+
# Check if any job failed or was cancelled
153+
if echo "$results" | grep -qE "failure|cancelled"; then
154+
echo "❌ One or more CI jobs failed or were cancelled"
155+
exit 1
156+
fi
157+
158+
echo "✅ All CI jobs passed (or were skipped because no relevant changes)"

.github/workflows/ci-python-agentframework-sampleagent.yml

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,13 @@
1+
# Copyright (c) Microsoft Corporation.
2+
# Licensed under the MIT License.
3+
14
name: CI - Build Python Agent Framework Sample Agent
25
permissions:
36
contents: read
47

58
on:
6-
push:
7-
branches: [ main, master ]
8-
paths:
9-
- 'python/agent-framework/sample-agent/**/*'
10-
- '.github/workflows/ci-python-agentframework-sampleagent.yml'
11-
pull_request:
12-
branches: [ main, master ]
13-
paths:
14-
- 'python/agent-framework/sample-agent/**/*'
15-
- '.github/workflows/ci-python-agentframework-sampleagent.yml'
9+
workflow_call: # Called by orchestrator
10+
workflow_dispatch: # Manual trigger
1611

1712
jobs:
1813
validate-sample:

.github/workflows/ci-python-googleadk-sampleagent.yml

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,13 @@
1+
# Copyright (c) Microsoft Corporation.
2+
# Licensed under the MIT License.
3+
14
name: CI - Build Python Google ADK Sample Agent
25
permissions:
36
contents: read
47

58
on:
6-
push:
7-
branches: [ main, master ]
8-
paths:
9-
- 'python/google-adk/sample-agent/**/*'
10-
- '.github/workflows/ci-python-googleadk-sampleagent.yml'
11-
pull_request:
12-
branches: [ main, master ]
13-
paths:
14-
- 'python/google-adk/sample-agent/**/*'
15-
- '.github/workflows/ci-python-googleadk-sampleagent.yml'
9+
workflow_call: # Called by orchestrator
10+
workflow_dispatch: # Manual trigger
1611

1712
jobs:
1813
validate-sample:

.github/workflows/ci-python-openai-sampleagent.yml

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,13 @@
1+
# Copyright (c) Microsoft Corporation.
2+
# Licensed under the MIT License.
3+
14
name: CI - Build Python OpenAI Sample Agent
25
permissions:
36
contents: read
47

58
on:
6-
push:
7-
branches: [ main, master ]
8-
paths:
9-
- 'python/openai/sample-agent/**/*'
10-
- '.github/workflows/ci-python-openai-sampleagent.yml'
11-
pull_request:
12-
branches: [ main, master ]
13-
paths:
14-
- 'python/openai/sample-agent/**/*'
15-
- '.github/workflows/ci-python-openai-sampleagent.yml'
9+
workflow_call: # Called by orchestrator
10+
workflow_dispatch: # Manual trigger
1611

1712
jobs:
1813
validate-sample:

0 commit comments

Comments
 (0)