script: add more default trusted_clients to moonraker.conf template
the previous method of adding the host network range was too unreliable in some cases and didn't cover some popular usecases
This commit is contained in:
1 parent
b44e855a98
commit
7984c28fe5
2 files changed
+13
-3
No files matched your search
@@ -277,7 +277,13 @@ create_moonraker_conf(){
|
||||
sed -i "s|%LOG%|$LOG_PATH|" $MR_CONF
|
||||
sed -i "s|%MR_DB%|$MR_DB|" $MR_CONF
|
||||
sed -i "s|%UDS%|$KLIPPY_UDS|" $MR_CONF
|
||||
sed -i "s|%LAN%|$LAN|" $MR_CONF
|
||||
# if host ip is not in the default ip ranges, replace placeholder
|
||||
# otherwise remove placeholder from config
|
||||
if ! grep $LAN $MR_CONF; then
|
||||
sed -i "s|%LAN%|$LAN|" $MR_CONF
|
||||
else
|
||||
sed -i "/%LAN%/d" $MR_CONF
|
||||
fi
|
||||
sed -i "s|%USER%|${USER}|g" $MR_CONF
|
||||
ok_msg "moonraker.conf created!"
|
||||
else
|
||||
|
||||
Reference in new issue
Block a user