This commit is contained in:
parent
1d36cdba41
commit
28a83e30f5
@ -38,7 +38,7 @@ server ntp5.aliyun.com iburst
|
||||
driftfile /var/lib/chrony/drift
|
||||
allow 127.0.0.1
|
||||
EOF
|
||||
if command -v systemctl >/dev/null 2>&1; then
|
||||
if pidof systemd >/dev/null 2>&1; then
|
||||
systemctl restart chrony && systemctl enable chrony
|
||||
else
|
||||
echo "systemctl 不存在,跳过 chrony 的重启"
|
||||
|
@ -21,7 +21,7 @@ cat > /etc/docker/daemon.json <<EOF
|
||||
}
|
||||
EOF
|
||||
|
||||
if command -v systemctl >/dev/null 2>&1; then
|
||||
if pidof systemd >/dev/null 2>&1; then
|
||||
systemctl restart docker
|
||||
else
|
||||
echo "systemctl 不存在,跳过 docker 重启。"
|
||||
|
Loading…
x
Reference in New Issue
Block a user