mirror of
https://github.com/tteck/Proxmox.git
synced 2025-02-15 06:09:15 +01:00
Updated the service creation to use cat instead of echo
This commit is contained in:
parent
4ae38ab9af
commit
cbcbd504e3
1 changed files with 3 additions and 4 deletions
|
@ -25,13 +25,11 @@ wget -q $(curl -s https://api.github.com/repos/ventoy/pxe/releases/latest | grep
|
|||
tar -C /tmp -xzf iventoy*.tar.gz
|
||||
mv /tmp/iventoy*/* /opt/iventoy/
|
||||
rm -rf iventoy*.tar.gz
|
||||
|
||||
|
||||
msg_ok "Installed iVentoy"
|
||||
|
||||
msg_info "Creating Service"
|
||||
service_path="/etc/systemd/system/iventoy.service"
|
||||
echo "# /etc/systemd/system/iventoy.service
|
||||
cat <<EOF >/etc/systemd/system/iventoy.service
|
||||
[Unit]
|
||||
Description =iVentoy PXE Booter
|
||||
Documentation =https://www.iventoy.com
|
||||
|
@ -46,7 +44,8 @@ ExecStart =sh ./iventoy.sh -R start
|
|||
WorkingDirectory =/opt/iventoy
|
||||
Restart =on-failure
|
||||
[Install]
|
||||
WantedBy=multi-user.target" >$service_path
|
||||
WantedBy=multi-user.target
|
||||
EOF
|
||||
systemctl enable --now iventoy.service
|
||||
msg_ok "Created Service"
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue