Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
adam.huang
Config
Commits
8f897bf4
Commit
8f897bf4
authored
Mar 07, 2019
by
Igor Pecovnik
Browse files
Enable Transmission web interface for local network by default
parent
dbceb66d
Changes
1
Hide whitespace changes
Inline
Side-by-side
debian-software
View file @
8f897bf4
...
...
@@ -169,7 +169,7 @@ function check_status
# Transmission
TRANSMISSION_STATUS
=
"$(check_if_installed transmission-daemon && echo "
on
" || echo "
off
" )"
alive_port
"Torrent download server"
"9091"
"boolean"
alive_port
"Torrent download server"
"9091"
LIST
+=
(
"Transmission"
"
$DESCRIPTION
"
"
$TRANSMISSION_STATUS
"
)
...
...
@@ -748,15 +748,16 @@ install_transmission ()
#
install_packet "debconf-utils unzip build-essential html2text apt-transport-https" "Downloading dependencies"
install_packet "transmission-cli transmission-common transmission-daemon" "Install torrent server"
# systemd workaround
# https://forum.armbian.com/index.php?/topic/4017-programs-does-not-start-automatically-at-boot/
sed -e 's/exit 0//g' -i /etc/rc.local
cat >> /etc/rc.local
<
<"
EOF
"
service transmission-daemon stop
local A=(${serverIP//./ })
local
servernetwork=
"${A[0]}.${A[1]}.*.*"
sed
"
s
/\"
rpc-whitelist
\"
:
\"127.0.0.1.
*
/\"
rpc-whitelist
\"
:
\"127.0.0.1,$
servernetwork
\"/"
-i
/
etc
/
transmission-daemon
/
settings.json
local servernetwork="${A[0]}.${A[1]}.*.*"
sed "s/\"rpc-whitelist\": \"127.0.0.1.*/\"rpc-whitelist\": \"127.0.0.1,$servernetwork\"
,
/" -i /etc/transmission-daemon/settings.json
service transmission-daemon start
# systemd workaround
# https://forum.armbian.com/index.php?/topic/4017-programs-does-not-start-automatically-at-boot/
sed -e 's/exit 0//g' -i /etc/rc.local
cat >> /etc/rc.local
<
<"
EOF
"
service
transmission-daemon
restart
exit
0
EOF
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment