RustDesk Server: write the creds file with heredocs

Matches how the other install scripts write their creds; the file is unchanged.
This commit is contained in:
MickLesk
2026-10-11 15:47:06 +02:00
parent 3bc994cad0
commit 752f9f4e42

View File

@@ -42,17 +42,19 @@ write_creds() {
msg_error "hbbs did not create ${key_file}" msg_error "hbbs did not create ${key_file}"
exit 1 exit 1
fi fi
{ cat <<EOF >~/rustdesk.creds
echo "RustDesk Server" RustDesk Server
echo "ID Server: ${LOCAL_IP}" ID Server: ${LOCAL_IP}
echo "Key: $(<"$key_file")" Key: $(<"$key_file")
if ((INSTALL_API)); then EOF
echo "" if ((INSTALL_API)); then
echo "RustDesk API Web UI: http://${LOCAL_IP}:21114/_admin/" cat <<EOF >>~/rustdesk.creds
echo "Username: admin"
echo "Password: ${API_PASS}" RustDesk API Web UI: http://${LOCAL_IP}:21114/_admin/
fi Username: admin
} >~/rustdesk.creds Password: ${API_PASS}
EOF
fi
} }
setup_deb_based() { setup_deb_based() {