mirror of
				https://github.com/linuxserver/docker-transmission.git
				synced 2025-10-31 17:05:48 +01:00 
			
		
		
		
	Merge pull request #307 from stavros-k/patch-1
This commit is contained in:
		| @@ -2,11 +2,12 @@ | ||||
| # shellcheck shell=bash | ||||
|  | ||||
| BLOCKLIST_ENABLED=$(jq -r '.["blocklist-enabled"]' /config/settings.json) | ||||
| PORT=$(jq '.["rpc-port"]' /config/settings.json) | ||||
|  | ||||
| if [[ "$BLOCKLIST_ENABLED" == true ]]; then | ||||
|     if [[ -n "$USER" ]] && [[ -n "$PASS" ]]; then | ||||
|         /usr/bin/transmission-remote -n "$USER":"$PASS" --blocklist-update | ||||
|         /usr/bin/transmission-remote 127.0.0.1:${PORT:-9091} -n "$USER":"$PASS" --blocklist-update | ||||
|     else | ||||
|         /usr/bin/transmission-remote --blocklist-update | ||||
|         /usr/bin/transmission-remote 127.0.0.1:${PORT:-9091} --blocklist-update | ||||
|     fi | ||||
| fi | ||||
|   | ||||
| @@ -2,11 +2,12 @@ | ||||
| # shellcheck shell=bash | ||||
|  | ||||
| pid=$(pidof transmission-daemon) | ||||
| PORT=$(jq '.["rpc-port"]' /config/settings.json) | ||||
|  | ||||
| if [[ -n "$USER" ]] && [[ -n "$PASS" ]]; then | ||||
|     /usr/bin/transmission-remote -n "$USER":"$PASS" --exit | ||||
|     /usr/bin/transmission-remote 127.0.0.1:${PORT:-9091} -n "$USER":"$PASS" --exit | ||||
| else | ||||
|     /usr/bin/transmission-remote --exit | ||||
|     /usr/bin/transmission-remote 127.0.0.1:${PORT:-9091} --exit | ||||
| fi | ||||
|  | ||||
| tail --pid=${pid} -f /dev/null | ||||
|   | ||||
		Reference in New Issue
	
	Block a user