Pull request: all: imp scripts
Merge in DNS/adguard-home from imp-sh to master Squashed commit of the following: commit 477832e11eca2ef7ac0071b5da938dacb2ed617d Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Wed May 19 20:24:34 2021 +0300 scripts: rm dbg commit dbb4b8c783f607781b980dcd57d78085c9022e72 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Wed May 19 20:21:20 2021 +0300 all: imp code, compat, docs commit e6e4375d67ad1c213efb04411e3ba0bc6293f936 Author: Ainar Garipov <A.Garipov@AdGuard.COM> Date: Wed May 19 19:33:48 2021 +0300 all: imp scripts
This commit is contained in:
@@ -1,10 +1,12 @@
|
||||
#!/bin/bash
|
||||
# Get admin tool port from configuration
|
||||
bind_port=$(grep bind_port $SNAP_DATA/AdGuardHome.yaml | awk -F ' ' '{print $2}')
|
||||
#!/bin/sh
|
||||
|
||||
if [ -z "$bind_port" ]; then
|
||||
xdg-open http://localhost:3000
|
||||
# Get the admin interface port from the configuration.
|
||||
bind_port="$( grep -e 'bind_port' "${SNAP_DATA}/AdGuardHome.yaml" | awk -F ' ' '{print $2}' )"
|
||||
readonly bind_port
|
||||
|
||||
if [ "$bind_port" = '' ]
|
||||
then
|
||||
xdg-open 'http://localhost:3000'
|
||||
else
|
||||
xdg-open http://localhost:$bind_port
|
||||
xdg-open "http://localhost:${bind_port}"
|
||||
fi
|
||||
|
||||
|
||||
Reference in New Issue
Block a user