fix nzbdrone config via nzbget. fixes #386

This commit is contained in:
clinton-hall 2014-05-10 08:02:26 +09:30
commit dda4395f06
3 changed files with 12 additions and 2 deletions

View file

@ -150,6 +150,11 @@
# Set the number of minutes to wait after calling the renamer, to check the episode has changed status.
#ndwait_for=2
# NzbDrone Delete Failed Downloads (0, 1).
#
# set to 1 to delete failed, or 0 to leave files in place.
#nddelete_failed=0
## HeadPhones
# HeadPhones script category.

View file

@ -55,6 +55,11 @@
# Set the number of minutes to wait after calling the renamer, to check the episode has changed status.
#ndwait_for=2
# NzbDrone Delete Failed Downloads (0, 1).
#
# set to 1 to delete failed, or 0 to leave files in place.
#nddelete_failed=0
## Extensions
# Media Extensions

View file

@ -315,8 +315,8 @@ class ConfigObj(configobj.ConfigObj, Section):
section = "NzbDrone"
envCatKey = 'NZBPO_NDCATEGORY'
envKeys = ['ENABLED', 'HOST', 'APIKEY', 'PORT', 'USERNAME', 'PASSWORD', 'SSL', 'WEB_ROOT', 'WATCH_DIR', 'FORK', 'DELETE_FAILED', 'TORRENT_NOLINK', 'NZBEXTRACTIONBY', 'WAIT_FOR']
cfgKeys = ['enabled', 'host', 'apikey', 'port', 'username', 'password', 'ssl', 'web_root', 'watch_dir', 'fork', 'delete_failed', 'Torrent_NoLink', 'nzbExtractionBy', 'wait_for']
envKeys = ['ENABLED', 'HOST', 'APIKEY', 'PORT', 'SSL', 'WEB_ROOT', 'WATCH_DIR', 'FORK', 'DELETE_FAILED', 'TORRENT_NOLINK', 'NZBEXTRACTIONBY', 'WAIT_FOR', 'DELETE_FAILED']
cfgKeys = ['enabled', 'host', 'apikey', 'port', 'ssl', 'web_root', 'watch_dir', 'fork', 'delete_failed', 'Torrent_NoLink', 'nzbExtractionBy', 'wait_for', 'delete_failed']
if os.environ.has_key(envCatKey):
for index in range(len(envKeys)):
key = 'NZBPO_ND' + envKeys[index]