瀏覽代碼

Install crontab on arch if not present during install

Nicolas Meienberger 3 年之前
父節點
當前提交
e227e4d148
共有 1 個文件被更改,包括 6 次插入2 次删除
  1. 6 2
      scripts/configure.sh

+ 6 - 2
scripts/configure.sh

@@ -49,10 +49,14 @@ else
     sudo systemctl start docker
     sudo systemctl start docker
     sudo systemctl enable docker
     sudo systemctl enable docker
   elif [[ "${OS}" == "arch" ]]; then
   elif [[ "${OS}" == "arch" ]]; then
-    sudo pacman -Sy --noconfirm docker cronie
-    systemctl enable --now cronie.service
+    sudo pacman -Sy --noconfirm docker
     sudo systemctl start docker.service
     sudo systemctl start docker.service
     sudo systemctl enable docker.service
     sudo systemctl enable docker.service
+
+    if ! command -v crontab >/dev/null; then
+      sudo pacman -Sy --noconfirm cronie
+      systemctl enable --now cronie.service
+    fi
   else
   else
     echo "Your OS ${OS} is not supported by this script. Please install docker and docker-compose manually."
     echo "Your OS ${OS} is not supported by this script. Please install docker and docker-compose manually."
     exit 1
     exit 1