feat: create Ansible playbook for single-node PicoClaw deployment (#1) - #2
Open
addidea wants to merge 1 commit into
Open
feat: create Ansible playbook for single-node PicoClaw deployment (#1)#2addidea wants to merge 1 commit into
addidea wants to merge 1 commit into
Conversation
Closes Clawland-AI#1 Complete Ansible automation for deploying PicoClaw on ARM64, RISC-V, or x86_64: **Playbook** (playbooks/deploy-picclaw.yml): - Installs system dependencies (Go, systemd, UFW) - Creates picclaw system user + directories - Downloads PicoClaw binary (architecture auto-detected) - Deploys config file from template - Creates systemd service with security hardening - Configures UFW firewall (SSH + PicoClaw port) - Health check verification (retry with timeout) **Templates**: 1. picclaw_config.yaml.j2 - Agent configuration (Jinja2) 2. picclaw.service.j2 - Systemd unit file with security **Inventory** (inventory/picclaw.ini): - Example hosts (Raspberry Pi, VPS) - Global variables (Telegram token, Fleet URL) **Documentation** (playbooks/README.md): - Quick start (3 commands) - Configuration variables - Multi-node deployment - Troubleshooting (5 common issues) - Architecture support table - Uninstallation guide **Features**: - Multi-architecture support (ARM64, RISC-V, x86_64) - Idempotent (safe to run multiple times) - Security hardening (NoNewPrivileges, ProtectSystem) - Automatic firewall setup (UFW) - Health check verification - Binary download with retry logic - Template-based configuration **Security Hardening**: - System user (no login shell) - Read-only system directories - Isolated /tmp - Resource limits (file descriptors, processes) - Firewall rules (deny all except SSH + app port) **Example Usage**: ```bash ansible-playbook -i inventory/picclaw.ini playbooks/deploy-picclaw.yml ``` Production-ready deployment automation! 🚀
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Complete Ansible automation for deploying PicoClaw on any Linux board (ARM64, RISC-V, x86_64).
Closes #1
What's Included
✅ Ansible Playbook (
playbooks/deploy-picclaw.yml)picclawaccount)✅ Configuration Templates (2 files)
picclaw_config.yaml.j2- Agent config (Fleet URL, Telegram, logging)picclaw.service.j2- Systemd unit (security hardened)✅ Inventory Example (
inventory/picclaw.ini)✅ Complete Documentation (
playbooks/README.md)Features
Multi-Architecture:
Security Hardening:
ProtectSystem=strict)PrivateTmp=true)NoNewPrivileges=true)Idempotent:
Reliable:
Usage
Quick Deploy
Multi-Node Deploy
# Deploy to 10 nodes in parallel ansible-playbook -i inventory/picclaw.ini playbooks/deploy-picclaw.yml -f 10Custom Variables
Systemd Service
Security hardening:
Resource limits:
Restart behavior:
Firewall (UFW)
Default rules:
Disable with:
-e "enable_firewall=false"Directory Structure
Testing
Verified on:
Troubleshooting
Health check timeout:
Binary download fails:
ansible-playbook ... -e "picclaw_binary_url=file:///path/to/binary"Permission denied:
Next Steps
Production-ready automation! 🚀