-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathci-deploy.yml
More file actions
50 lines (41 loc) · 1.49 KB
/
Copy pathci-deploy.yml
File metadata and controls
50 lines (41 loc) · 1.49 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
# Deploy your managed agents on every push — "git push to deploy".
#
# Copy this to YOUR repo at .github/workflows/deploy-agents.yml, add an
# ANTHROPIC_API_KEY repo secret, and commit your .managed-agents/ folder.
# On every push that touches it, the agents are (re)deployed and the updated
# .agentlift-lock.json (your local -> remote ID map) is committed back.
#
# Idempotent: unchanged skills/agents are skipped, so re-deploys are cheap.
name: deploy-managed-agents
on:
push:
branches: [main]
paths: [".managed-agents/**"]
workflow_dispatch:
permissions:
contents: write # to commit the updated lockfile back
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.12"
- name: Install agentlift
run: pip install agentlift
- name: Plan (fails the build on any error diagnostic)
run: agentlift validate .
- name: Deploy
env:
ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }}
run: agentlift deploy . --yes --prune
- name: Commit updated lockfile
run: |
if ! git diff --quiet -- .agentlift-lock.json; then
git config user.name "github-actions[bot]"
git config user.email "github-actions[bot]@users.noreply.github.com"
git add .agentlift-lock.json
git commit -m "chore: update agentlift deploy lockfile [skip ci]"
git push
fi