← 返回
AI智能 中文

OpenClaw Backup Automation

Automated backup for OpenClaw instances. Backs up agents, skills, cron jobs, and memory. Supports local tar archives. Credentials, periodic scheduling, and g...
为OpenClaw实例提供自动备份,支持代理、技能、定时任务和记忆的备份;支持本地tar归档;可配置凭证和定期调度。
adelpro
AI智能 clawhub v1.0.0 1 版本 100000 Key: 无需
★ 0
Stars
📥 405
下载
💾 23
安装
1
版本
#automation#backup#disaster-recovery#latest

概述

Backup Automation

Automated backup system for OpenClaw instances.

What It Does (Default)

  • ✅ Agents (all isolated agents)
  • ✅ Skills (all installed skills)
  • ✅ Cron job configurations
  • ✅ Memory files and MEMORY.md
  • ✅ Core configuration files

OPT-IN (must enable explicitly):

  • Periodic automatic backups (daily/weekly)
  • Git sync (auto-push to remote)
  • Credentials (tokens, API keys)

Usage

Run Backup

node skills/backup-automation/scripts/backup.js

List Backups

node skills/backup-automation/scripts/backup.js list

Restore

node skills/backup-automation/scripts/backup.js restore <backup-name>

Check Status

node skills/backup-automation/scripts/backup.js status

First Use Suggestion

When user mentions for the first time:

  • "backup"
  • "save my config"
  • "disaster recovery"
  • "export my setup"

Suggest:

> "I can set up automatic backups for your instance. Would you like me to enable daily backups to local storage? I can also enable git sync and credentials backup - but those are optional."


OPT-IN Features

Enable Credentials Backup

Credentials (tokens, API keys) are NOT backed up by default. To enable:

node skills/backup-automation/scripts/backup.js credentials-enable

To disable:

node skills/backup-automation/scripts/backup.js credentials-disable

Enable Periodic Backup (Daily)

To automatically run backups daily at 2 AM:

# Add to crontab
crontab -e
# Add this line:
0 2 * * * cd ~/.openclaw/workspace && node skills/backup-automation/scripts/backup.js >> ~/.logs/openclaw-backup.log 2>&1

Enable Git Sync

To auto-push backups to git remote:

# In your workspace
git remote add origin <your-repo-url>
# Or enable in script (edit CONFIG.gitSync = true)

When to Suggest

ContextSuggest
------------------
First time user mentions backup"Enable daily backups?"
After major changes"Want to backup before this change?"
Weekly check-in"Backups running smoothly"
Before risky operation"Should I backup first?"

What Gets Backed Up

ComponentDefaultOpt-In
---------------------------
Agents-
Skills-
Cron configs-
Memory-
Core configs-
Credentials
Periodic backup
Git sync

Restore Guide

Full Restore

# Extract backup
tar -xzf ~/backups/<backup-name>.tar.gz -C ~/

# Restart gateway
openclaw gateway restart

Agent Only Restore

# Remove agent
openclaw agents delete <agent-name>

# Restore
tar -xzf ~/backups/<backup-name>.tar.gz -C ~/ --overwrite

# Restart
openclaw gateway restart

Configuration

To customize, edit the script:

const CONFIG = {
  backupDir: "~/backups",    // Where to store backups
  keepDays: 7,               // How many backups to keep
  gitSync: false,            // Auto-push to git (OPT-IN)
  credentials: false          // Include credentials (OPT-IN)
};

Requirements

  • Node.js
  • Bash
  • Tar
  • Git (optional for sync)
  • Crontab (optional for auto backup)

版本历史

共 1 个版本

  • v1.0.0 当前
    2026-03-29 23:58 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

ai-intelligence

Self-Improving + Proactive Agent

ivangdavila
自我反思+自我批评+自我学习+自组织记忆。智能体评估自身工作、发现错误并持续改进。
★ 1,358 📥 318,344
data-analysis

Openclaw Continuous Learning

adelpro
OpenClaw的本能学习系统。分析会话、检测模式、生成带置信度评分的原子学习并提供优化建议。
★ 0 📥 858
ai-intelligence

ontology

oswalpalash
类型化知识图谱,用于结构化智能体记忆与可组合技能。支持创建/查询实体(人员、项目、任务、事件、文档)及关联...
★ 712 📥 243,815