zeabur-template-backup
Zeabur Template Backup
Always use
npx zeabur@latestto invoke Zeabur CLI. Never usezeaburdirectly or any other installation method. Ifnpxis not available, install Node.js first.
Backup an online Zeabur template to the local git repository with standardized naming.
When to Use
- User provides a Zeabur template URL (e.g.,
https://zeabur.com/templates/85IQXQ) - User asks to backup/save a Zeabur template
- User wants to create a local copy of an online Zeabur template
Repository Location
The backup repository path depends on your setup. Look for a zeabur-template directory in the user's workspace, or ask the user where to save templates. A common default:
~/Documents/zeabur/zeabur-template/
Naming Convention
{service-name}/zeabur-template-{service-name}-{TEMPLATE_CODE}.yaml
Examples:
elasticsearch-kibana/zeabur-template-elasticsearch-kibana-85IQXQ.yamldify/zeabur-template-dify-1D4DOW.yamlpostiz/zeabur-template-postiz-v2.12-X2L3BE.yaml
How to Download Template YAML
Zeabur templates can be directly downloaded by appending .yaml to the template URL:
https://zeabur.com/templates/{TEMPLATE_CODE}.yaml
Example:
- Template page:
https://zeabur.com/templates/1D4DOW - YAML download:
https://zeabur.com/templates/1D4DOW.yaml
Use curl to download:
curl -sL https://zeabur.com/templates/{TEMPLATE_CODE}.yaml -o output.yaml
Step-by-Step
For template YAML reference and editing, use the zeabur-template skill.
1. Extract Template Code from URL
URL format: https://zeabur.com/templates/{TEMPLATE_CODE}
Example: https://zeabur.com/templates/85IQXQ → Code is 85IQXQ
2. Download YAML and Extract Template Name
# Download YAML
curl -sL https://zeabur.com/templates/{TEMPLATE_CODE}.yaml -o /tmp/template.yaml
# Extract template name from YAML metadata.name field
grep -A1 'metadata:' /tmp/template.yaml | grep 'name:' | head -1
3. Derive Service Name
- Convert template name to lowercase kebab-case
- Example: "Elasticsearch Single Node with Kibana" →
elasticsearch-kibana - Keep it short and descriptive
4. Create Directory and Save
REPO=~/Documents/zeabur/zeabur-template # adjust to your actual path
# Create directory
mkdir -p $REPO/{service-name}
# Move YAML with naming pattern
mv /tmp/template.yaml $REPO/{service-name}/zeabur-template-{service-name}-{TEMPLATE_CODE}.yaml
5. Git Commit
cd $REPO
git add {service-name}/
git commit -m "feat({service-name}): add {Template Name} template"
6. Push (if requested)
git push
Quick Reference
| Step | Action |
|---|---|
| 1 | Extract template code from URL |
| 2 | Download YAML via curl -sL .../{CODE}.yaml |
| 3 | Read template name from YAML metadata.name |
| 4 | Derive kebab-case service name |
| 5 | Save to {service-name}/zeabur-template-{service-name}-{CODE}.yaml |
| 6 | Git commit with conventional format |
| 7 | Push if user requests |
Common Issues
| Issue | Solution |
|---|---|
| curl returns HTML instead of YAML | Verify the template code is correct |
| Template name has special chars | Use simple kebab-case for directory |
| Already exists | Compare with existing file, update if needed |
More from zeabur/zeabur-claude-plugin
zeabur-deployment-logs
Use when viewing service runtime or build logs. Use when user says "show logs", "why did deploy fail", "check build output", or "debug runtime error".
54zeabur-template
Use when creating, editing, validating, or troubleshooting a Zeabur template YAML. Use when converting docker-compose to Zeabur template. Do NOT use for deploying templates (use zeabur-template-deploy instead).
53zeabur-restart
Use when restarting a Zeabur service. Use when user says "restart", "reboot service", or "service is stuck/frozen".
53zeabur-domain-url
Use when services need public URL for redirects or CORS. Use when WEB_URL or similar has trailing slash issues. Use when user reports "redirect goes to wrong URL", "CORS error", or "trailing slash problem". Also use when user says "add domain", "set up domain", "bind domain", "create domain", or "manage domains" for a Zeabur service.
52zeabur-variables
Use for ALL Zeabur environment variable operations — create, list, update, delete, or troubleshoot. Use when user says "set env var", "add variable", "create variable", "update variable", "delete variable", "change env var", or "why is my variable empty". Also use when variables are empty or SERVICE_NOT_FOUND errors.
51zeabur-update-service
Use when modifying service config without full redeploy. Use when updating env vars and restarting single service. Use when user says "change env var", "update config", "fix variable without redeploying", "upgrade service version", "update image tag", or "change service tag".
49