Files
sh/beifen.sh
openclaw 0784a11c19
Some checks failed
Weekly Translation Workflow / translate (push) Has been cancelled
init: fork of kejilion/sh with certbot host-network fix
- Replace 'docker run -p 80:80' with '--network host' for certbot standalone HTTP-01 to avoid timeout in environments where Docker NAT port-publish breaks LE inbound traffic but host port 80 is reachable.
- Applies to kejilion.sh (all locale variants) and auto_cert_renewal.sh.
- README install command points to this Gitea mirror.
2026-05-18 17:06:42 +08:00

11 lines
413 B
Bash

#!/bin/bash
# Create a tar archive of the web directory
cd /home/ && tar czvf web_$(date +"%Y%m%d%H%M%S").tar.gz web
# Transfer the tar archive to another VPS
cd /home/ && ls -t /home/*.tar.gz | head -1 | xargs -I {} sshpass -p 123456 scp -o StrictHostKeyChecking=no -P 22 {} root@0.0.0.0:/home/
# Keep only 5 tar archives and delete the rest
cd /home/ && ls -t /home/*.tar.gz | tail -n +4 | xargs -I {} rm {}