浏览代码

Update homarr-install.sh

fixes https://github.com/tteck/Proxmox/issues/2054
tteckster 1 年之前
父节点
当前提交
6ef30fbeb9
共有 1 个文件被更改,包括 3 次插入1 次删除
  1. 3 1
      install/homarr-install.sh

+ 3 - 1
install/homarr-install.sh

@@ -36,7 +36,9 @@ $STD npm install -g yarn
 msg_ok "Installed Node.js/Yarn"
 
 msg_info "Installing Homarr (Patience)"
-git clone -q https://github.com/ajnart/homarr.git /opt/homarr
+mkdir -p /opt/homarr
+RELEASE=$(curl -s https://api.github.com/repos/ajnart/homarr/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }')
+wget -O- https://github.com/ajnart/homarr/archive/refs/tags/v${RELEASE}.tar.gz | tar -xz -C /opt && mv /opt/homarr-${RELEASE} /opt/homarr
 cd /opt/homarr
 cp -p /opt/homarr/.env.example /opt/homarr/.env
 sed -i 's|NEXTAUTH_SECRET="[^"]*"|NEXTAUTH_SECRET="'"$(openssl rand -base64 32)"'"|' /opt/homarr/.env