Initial commit: VaultMesh Skills collection
Collection of operational skills for VaultMesh infrastructure including: - backup-sovereign: Backup and recovery operations - btc-anchor: Bitcoin anchoring - cloudflare-tunnel-manager: Cloudflare tunnel management - container-registry: Container registry operations - disaster-recovery: Disaster recovery procedures - dns-sovereign: DNS management - eth-anchor: Ethereum anchoring - gitea-bootstrap: Gitea setup and configuration - hetzner-bootstrap: Hetzner server provisioning - merkle-forest: Merkle tree operations - node-hardening: Node security hardening - operator-bootstrap: Operator initialization - proof-verifier: Cryptographic proof verification - rfc3161-anchor: RFC3161 timestamping - secrets-vault: Secrets management 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
28
dns-sovereign/scripts/rollback/undo_zone.sh
Normal file
28
dns-sovereign/scripts/rollback/undo_zone.sh
Normal file
@@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
|
||||
SKILL_ROOT="$(dirname "$(dirname "$SCRIPT_DIR")")"
|
||||
source "$SKILL_ROOT/scripts/_common.sh"
|
||||
|
||||
: "${PDNS_API_KEY:=}"
|
||||
: "${PDNS_WEB_PORT:=8081}"
|
||||
: "${ZONE_NAME:=}"
|
||||
|
||||
api() {
|
||||
local method="$1"; shift
|
||||
local url="$1"; shift
|
||||
curl -sS -X "$method" "$url" -H "X-API-Key: $PDNS_API_KEY" -H "Content-Type: application/json" "$@"
|
||||
}
|
||||
|
||||
main() {
|
||||
confirm_gate
|
||||
[[ -n "$PDNS_API_KEY" ]] || die "PDNS_API_KEY required."
|
||||
[[ -n "$ZONE_NAME" ]] || die "ZONE_NAME required."
|
||||
|
||||
local zone="${ZONE_NAME%\.}."
|
||||
local base="http://127.0.0.1:${PDNS_WEB_PORT}/api/v1/servers/localhost"
|
||||
log_warn "Deleting zone: $zone"
|
||||
api DELETE "$base/zones/$zone" | jq '.' || die "Failed to delete zone."
|
||||
log_info "Zone rollback complete."
|
||||
}
|
||||
main "$@"
|
||||
Reference in New Issue
Block a user