acme.sh數據遷移

acme.sh數據遷移

1.1.安裝腳本

  • 在新服務器安裝 acme.sh 腳本工具
curl  https://get.acme.sh | sh
# or
wget -O -  https://get.acme.sh | sh

ll ~/.acme.sh/
alias acme.sh=~/.acme.sh/acme.sh
ll ~/.acme.sh/

1.2.打包備份 acme.sh 數據

cd /root/
ll -a
tar -zcvf acme.sh.tgz .acme.sh/
sz -y acme.sh.tgz

1.3.在新服務器解壓備份的數據包

  • 上傳 acme.sh.tgz
cd /root/
ll -a
mv .acme.sh/ .acme.sh.bak
rz -y
tar xf acme.sh.tgz
ls -lha

1.4.修改定時任務

crontab -e
-----------------------------
27 0 * * * "/root/.acme.sh"/acme.sh --cron --home "/root/.acme.sh" > /dev/null
-----------------------------
  • 實例演示:運行測試
"/root/.acme.sh"/acme.sh --cron --home "/root/.acme.sh"
----------------------
root@zuiyoujie:~/.acme.sh# "/root/.acme.sh"/acme.sh --cron --home "/root/.acme.sh"
[Mon Dec 27 13:31:44 CST 2021] ===Starting cron===
[Mon Dec 27 13:31:45 CST 2021] Already uptodate!
[Mon Dec 27 13:31:45 CST 2021] Upgrade success!
[Mon Dec 27 13:31:45 CST 2021] Auto upgraded to: 3.0.2
[Mon Dec 27 13:31:45 CST 2021] Renew: 'www.zuiyoujie.com'
[Mon Dec 27 13:31:45 CST 2021] Renew: 'zuiyoujie.com'
[Mon Dec 27 13:31:45 CST 2021] Add '--force' to force to renew.
[Mon Dec 27 13:31:45 CST 2021] Skipped zuiyoujie.com
[Mon Dec 27 13:31:45 CST 2021] ===End cron===
-------------------
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章