diff --git a/debian/changelog b/debian/changelog index 323d052..28f73a5 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,7 +1,9 @@ nzbget (17.0+dfsg-1) UNRELEASED; urgency=medium * New Upstream Release - * Add WebDir and ConfigTemplate to sample configuration (LP: #1576471) + * debian/nzbget.conf: + - Add WebDir and ConfigTemplate to sample configuration (LP: #1576471) + - Update sample configuration file -- Andreas Moog Sun, 31 Jul 2016 15:13:43 +0200 diff --git a/debian/nzbget.conf b/debian/nzbget.conf index b48233a..87a2c0a 100644 --- a/debian/nzbget.conf +++ b/debian/nzbget.conf @@ -1,19 +1,4 @@ -# Sample configuration file for NZBGet -# -# On POSIX put this file to one of the following locations: -# ~/.nzbget -# /etc/nzbget.conf -# /usr/etc/nzbget.conf -# /usr/local/etc/nzbget.conf -# /opt/etc/nzbget.conf -# -# On Windows put this file in program's directory. -# -# You can also put the file into any location, if you specify the path to it -# using switch "-c", e.g: -# nzbget -c /home/user/myconfig.txt - -# For quick start change the option MainDir and configure one news-server +# Configuration file for NZBGet ############################################################################## @@ -29,6 +14,11 @@ # # If you want to distinguish between partially downloaded files and # completed downloads, use also option . +# +# It is allowed to enter multiple directories here by separating them with comma +# or semicolon. NZBGet checks how much free disk space is available in each +# directory (assuming all directories are located on different drives) and +# chooses the directory with the most free space. DestDir=${MainDir}/dst # Directory to store intermediate files. @@ -51,7 +41,7 @@ # Directory for incoming nzb-files. # # If a new nzb-file is added to queue via web-interface or RPC-API, it -# is saved into this directory and then processed by pre-processing +# is saved into this directory and then processed by preprocessing # script (option ). # # This directory is also monitored for new nzb-files. If a new file @@ -80,6 +70,8 @@ # Directory with post-processing and other scripts. # +# This option may contain multiple directories separated with commas or semicolons. +# # NOTE: For information on writing scripts visit http://nzbget.net/Extension_scripts. ScriptDir=${MainDir}/scripts @@ -129,6 +121,7 @@ # available on program start. RequiredDir= + ############################################################################## ### NEWS-SERVERS ### @@ -168,6 +161,19 @@ # Several servers with the same level may be defined, they have # the same priority. Server1.Level=0 + +# This is an optional non-reliable server (yes, no). +# +# Marking server as optional tells NZBGet to ignore this server if a +# connection to this server cannot be established. Normally NZBGet +# doesn't try upper-level servers before all servers on current level +# were tried. If a connection to server fails NZBGet waits until the +# server becomes available (it may try others from current level at this +# time). This is usually what you want to avoid exhausting of +# (costly) upper level servers if one of main servers is temporary +# unavailable. However, for less reliable servers you may prefer to ignore +# connection errors and go on with higher-level servers instead. +Server1.Optional=no # Group of news server (0-99). # @@ -259,7 +265,7 @@ # IP on which NZBGet server listen and which clients use to contact NZBGet. # -# It could be a dns-hostname (e. g. "mypc") or an ip-address (e. g. "192.168.1.2" or +# It could be a dns-hostname (e. g. "mypc") or an IP address (e. g. "192.168.1.2" or # "127.0.0.1"). An IP-address is more effective because does not require dns-lookup. # # Your computer may have multiple network interfaces and therefore multiple IP @@ -297,10 +303,10 @@ # User name for restricted access. # -# Restricted user can control the program with few restrictions. He -# has access to web-interface and can see most program settings. He -# can not change program settings and can not view security related -# options or options provided by extension scripts. +# The restricted user can control the program with a few restrictions. +# They have access to the web-interface and can see most of the program +# settings. They however, can not change program settings, view security +# related options or options provided by extension scripts. # # Use this user to connect to NZBGet from other programs and web-sites. # @@ -428,7 +434,7 @@ # is usually supplied by nzb-site or by application accessing # NZBGet. Using Aliases you can match their categories with your owns. # -# Separate aliases with commas or semicolons. Use wildcard-characters +# Separate aliases with commas or semicolons. Use wildcard characters # * and ? for pattern matching. # # Example: TV - HD, TV - SD, TV* @@ -476,7 +482,7 @@ # [A:|A(options):|R:|Q:|O(options):|#] search-string # # A - declares Accept-rule. Rules are accept-rules by default, the -# "A:" can be imitted. If the feed item matches to the rule the +# "A:" can be omitted. If the feed item matches to the rule the # item is considered good and no further rules are checked. # R - declares Reject-rule. If the feed item matches to the rule the # item is considered bad and no further rules are checked. @@ -532,7 +538,7 @@ # # + - declares a positive term. Terms are positive by default, # the "+" can be omitted; -# - - declares a negative term. If the term succeed the feed +# - - declares a negative term. If the term succeeds the feed # item is ignored; # field - field to which apply the term. If not specified # the default field "title" is used; @@ -560,7 +566,7 @@ # Any newznab attribute (encoded as "newznab:attr" in the RSS feed) can # be used as search field with prefix "attr-", for example "attr-genre". # -# Text search (Command @) supports supports wildcard characters * (matches +# Text search (Command @) supports wildcard characters * (matches # any number of any characters), ? (matches any one character) # and # (matches one digit). # Text search is by default performed against words (word-search mode): the @@ -588,19 +594,19 @@ # http://nzbget.net/RSS. #Feed1.Filter= +# How often to check for new items (minutes). +# +# Value "0" disables the automatic check of this feed. +#Feed1.Interval=15 + # Treat all items on first fetch as backlog (yes, no). # # yes - when the feed is fetched for the very first time (or after # changing of URL or filter) all existing items are ignored (marked -# as backlog). The items found on subsequentional fetches are processed; +# as backlog). The items found on subsequent fetches are processed; # no - all items are processed even on first fetch (or after # changing of URL or filter). #Feed1.Backlog=yes - -# How often to check for new items (minutes). -# -# Value "0" disables the automatic check of this feed. -#Feed1.Interval=15 # Add nzb-files as paused (yes, no). #Feed1.PauseNzb=no @@ -626,6 +632,7 @@ # For more information see global option . #Feed1.FeedScript= + ############################################################################## ### INCOMING NZBS ### @@ -655,7 +662,7 @@ # 1) if history contains the same title (see below) with success status # the nzb-file is not added to queue; # 2) if download queue already contains the same title the nzb-file is -# added to queue for backup (if firt file fails); +# added to queue for backup (if the first file fails); # 3) if nzb-file contains duplicate entries. This helps to find errors # in bad nzb-files. # @@ -668,7 +675,7 @@ # duplicates are deleted from queue. # # NOTE: For automatic duplicate handling option must be -# set to "Delete" or "None". If it is set to "Pause" you will need to +# set to "Delete", "Park" or "None". If it is set to "Pause" you will need to # manually unpause another duplicate (if any exists in queue). # # NOTE: For more info on duplicates see http://nzbget.net/RSS. @@ -705,7 +712,7 @@ # download-jobs (nzb-files) itself. Download-jobs are always # continued regardless of that option. # -# Disabling this option may slighlty reduce disk access and is +# Disabling this option may slightly reduce disk access and is # therefore recommended on fast connections. ContinuePartial=yes @@ -813,7 +820,7 @@ # How many retries should be attempted if a download error occurs (0-99). # # If download fails because of incomplete or damaged article or due to -# CRC-error the program tries to redownload the article from the same +# CRC-error the program tries to re-download the article from the same # news server as many times as defined in option . If all # attempts fail the program tries another news server. # @@ -878,15 +885,6 @@ # Value "0" disables the check. DiskSpace=250 -# Delete already downloaded files from disk when nzb-file is deleted -# (yes, no). -# -# This option defines if downloaded files must be deleted when: -# 1) download of nzb-file is cancelled (deleted from queue); -# 2) history record with failure-status (par-failure or unpack-failure) -# is deleted from history. -DeleteCleanupDisk=yes - # Delete source nzb-file when it is not needed anymore (yes, no). # # Enable this option for automatic deletion of source nzb-file from @@ -898,13 +896,13 @@ # # After download and post-processing the items are added to history where # their status can be checked and they can be post-processed again if -# neccessary. +# necessary. # # After expiring of defined period: # # If option is active the items become hidden and the amount # of data kept is significantly reduced (for better performance), only -# fields necessary for duplicate check are kept. The item remain in the +# fields necessary for duplicate check are kept. The item remains in the # hidden history (forever); # # If option is NOT active the items are removed from history. @@ -928,7 +926,7 @@ # days. Keeping of items for few days helps in situations when feed provider # has technical issues and may response with empty feeds (or with missing # items). When the technical issue is fixed the items may reappear in the -# feed causing the program to redownload items if they were not found in +# feed causing the program to re-download items if they were not found in # the feed history. FeedHistory=7 @@ -945,6 +943,28 @@ # via URL or fetching of RSS feeds and nzb-files from feeds) are performed # even if download is in paused state. UrlForce=yes + +# Monthly download volume quota (megabytes). +# +# During download the quota is constantly monitored and the downloading +# is automatically stopped if the limit is reached. Once the next billing month +# starts the "quota reached"-status is automatically lifted and the downloading +# continues. +# +# Downloads with force-priority are processed regardless of quota status. +# +# Value "0" disables monthly quota check. +MonthlyQuota=0 + +# Day of month when the monthly quota starts (1-31). +QuotaStartDay=1 + +# Daily download volume quota (megabytes). +# +# See option for details. +# +# Value "0" disables daily quota check. +DailyQuota=0 ############################################################################## @@ -1003,7 +1023,7 @@ # # Core-files are very helpful for debugging. # -# NOTE: Core-files may contain sensible data, like your login/password to +# NOTE: Core-files may contain sensitive data, like your login/password to # newsserver etc. DumpCore=no @@ -1014,7 +1034,7 @@ # to the log-file and by option "TaskX.Time" in the scheduler settings. # # The option is usually not needed if the time zone is set up correctly. -# However, sometimes, especially when using a binary compiled on onother +# However, sometimes, especially when using a binary compiled on another # platform (cross-compiling) the conversion between system and local time # may not work properly and requires adjustment. # @@ -1022,8 +1042,6 @@ # Example 1: set time correction to one hour: TimeCorrection=1; # Example 2: set time correction to one hour and a half: TimeCorrection=90. TimeCorrection=0 - -# See also option in section "PATHS" ############################################################################## @@ -1070,7 +1088,7 @@ # Time to execute the command (HH:MM). # # Multiple comma-separated values are accepted. -# Asterix as hours-part means "every hour". +# An asterisk placed in the hours location will run every hour. # # Examples: "08:00", "00:00,06:00,12:00,18:00", "*:00", "*:00,*:30". # @@ -1114,17 +1132,17 @@ # Some scheduler commands require additional parameters: # DownloadRate - download rate limit to be set (kilobytes/sec). # Example: 1000; -# Script - list of scheduler scripts to execute. The scripts in -# the list must be separated with commas or semicolons. Only -# filenames without path must be used. All scripts must be -# stored in directory pointed by option . For -# more info see below; +# Script - list of scheduler scripts to execute. The scripts in the +# list must be separated with commas or semicolons. All +# scripts must be stored in directory set by option +# and paths relative to must be +# entered here. For more info see below; # Process - path to the program to execute and its parameters. # Example: /home/user/fetch.sh. # If filename or any parameter contains spaces it # must be surrounded with single quotation # marks. If filename/parameter contains single quotation marks, -# each of them must be replaced with two single quotation +# each of them must be replaced (escaped) with two single quotation # marks and the resulting filename/parameter must be # surrounded with single quotation marks. # Example: '/home/user/download/my scripts/task process.sh' 'world''s fun'. @@ -1187,7 +1205,7 @@ # the option is enabled; # Manual - par-check is skipped. One par2-file is always # downloaded. If a damaged download is detected, all -# par2-files are downloaded but neithet par-check nor par-repair +# par2-files are downloaded but neither par-check nor par-repair # take place. The download can be then repaired manually, # eventually on another faster computer. ParCheck=auto @@ -1207,8 +1225,8 @@ # # If option is set to "Auto" or "Force" this option defines # if the download must be repaired when needed. The option can be -# disabled if computer does not have enough CPU power, since repairing -# may take too much resources and time on a slow computers. +# disabled if a computer does not have enough CPU power, since repairing +# may consume too many resources and time on a slow computer. ParRepair=yes # What files should be scanned during par-verification (limited, extended, @@ -1274,28 +1292,27 @@ # will ignore files matching this option and will not initiate # repair. This avoids time costing repair for unimportant files. # -# NOTE: Files matching the option are ignored as well. -# # Example: .sfv, .nzb, .nfo ParIgnoreExt=.sfv, .nzb, .nfo -# What to do if download health drops below critical health (delete, +# What to do if download health drops below critical health (delete, park, # pause, none). # -# Delete - delete nzb-file from queue. If option -# is active the already downloaded files will be deleted too; +# Delete - delete nzb-file from queue, also delete already downloaded files; +# Park - move nzb-file to history, keep already downloaded files. Commands +# "Download remaining files" and "Retry failed articles" are available +# for this nzb; # Pause - pause nzb-file; # None - do nothing (continue download). # -# NOTE: For automatic duplicate handling option must be set to "Delete" -# or "None". If it is set to "Pause" you will need to manually return -# another duplicate to queue (if any exists in history). See also -# option . -# -# NOTE: When option is set to "Dupe" the delete-action is performed +# NOTE: For automatic duplicate handling option must be set to "Delete", "Park" +# or "None". If it is set to "Pause" you will need to manually move another +# duplicate from history to queue. See also option . +# +# NOTE: When option is set to "Dupe" the park-action is performed # only if article completion is below 10% (empirical threshold). This is to # improve efficiency of dupe par scan mode. -HealthCheck=delete +HealthCheck=park # Maximum allowed time for par-repair (minutes). # @@ -1313,7 +1330,7 @@ # Value "0" means unlimited. # # NOTE: The option limits only the time required for repairing. It doesn't -# affect the first stage of parcheck - verification of files. However the +# affect the first stage of parcheck - verification of files. However, the # verification speed is constant, it doesn't depend on files integrity and # therefore it is not necessary to limit the time needed for the first stage. ParTimeLimit=0 @@ -1328,12 +1345,6 @@ # # NOTE: See also options and . ParPauseQueue=no - -# Cleanup download queue after successful check/repair (yes, no). -# -# Enable this option for automatic deletion of unneeded (paused) par-files -# from download queue after successful check/repair. -ParCleanupQueue=yes ############################################################################## @@ -1378,11 +1389,11 @@ # Switch "x" is added only if neither "x" nor "e" were defined in # the option (this allows you to use switch "e" instead of "x"). switch # "-o+" is added only if neither "-o+" nor "-o-" were defined -# in the command line. All other paramaters are always added. Parameter +# in the command line. All other parameters are always added. Parameter # "-p-" is replaced with "-ppassword" if a password is set for nzb-file. # # Examples: -# 1) ignore file attributes (pemissions): +# 1) ignore file attributes (permissions): # /usr/bin/unrar x -ai; # 2) decrease priority of unrar-process: # nice -n 19 unrar. @@ -1415,10 +1426,6 @@ # extensions, file names or file masks containing wildcard # characters * and ?. # -# Files listed here are also ignored by par-rename and par-check. -# -# NOTE: See also option . -# # Example: .par2, .sfv ExtCleanupDisk=.par2, .sfv, _brokenlog.txt @@ -1435,15 +1442,16 @@ # passwords should be set per nzb-file in their post-processing settings. UnpackPassFile= + ############################################################################## ### EXTENSION SCRIPTS ### # Default list of post-processing scripts to execute after the download # of nzb-file is completed and possibly par-checked/repaired and unpacked. # -# The scripts in the list must be separated with commas or semicolons. Only -# filenames without path must be used. All scripts must be stored in directory -# pointed by option . +# The scripts in the list must be separated with commas or semicolons. All +# scripts must be stored in directory set by option and +# paths relative to must be entered here. # # Example: Cleanup.sh, Move.sh, EMail.py. # @@ -1471,12 +1479,13 @@ # # NZBGet passes following arguments to post-processing script as environment # variables: -# NZBPP_DIRECTORY - path to destination dir for downloaded files; +# NZBPP_DIRECTORY - path to destination directory for downloaded files; # NZBPP_NZBNAME - user-friendly name of processed nzb-file as it is displayed # by the program. The file path and extension are removed. # If download was renamed, this parameter reflects the new name; -# NZBPP_NZBFILENAME - name of processed nzb-file. It includes file extension and also -# may include full path; +# NZBPP_NZBFILENAME - original name of processed nzb-file. It includes file extension +# and may include full path; +# NZBPP_QUEUEDFILE - full filename of the queued (renamed) nzb-file; # NZBPP_FINALDIR - final destination path if set by one of previous pp-scripts; # NZBPP_CATEGORY - category assigned to nzb-file (can be empty string); # NZBPP_DUPEKEY - duplicate key of nzb-file; @@ -1548,12 +1557,12 @@ # or: # echo "[NZB] FINALDIR=/path/to/moved/files"; # -# Command "DIRECTORY" changes the destiantion path of the download and +# Command "DIRECTORY" changes the destination path of the download and # affects the scripts executed after the current script as well as the # program code itself, for example the command "Post-process again" # will work on new location. Command "FINALDIR" just sets a separate # property of the download and should be used when the files are moved -# into an existing directory containg other files to avoid the processing +# into an existing directory containing other files to avoid the processing # of those files by other scripts. # # To assign post-processing parameters: @@ -1570,7 +1579,7 @@ # 93 - post-process successful (status = SUCCESS); # 94 - post-process failed (status = FAILURE); # 95 - post-process skipped (status = NONE). Use this code when you script -# terminates immediateley without doing any job and when this is not +# terminates immediately without doing any job and when this is not # a failure termination; # 92 - request NZBGet to do par-check/repair for current nzb-file. # @@ -1582,9 +1591,9 @@ # List of scan scripts to execute before a nzb-file is added to queue. # -# The scripts in the list must be separated with commas or semicolons. Only -# filenames without path must be used. All scripts must be stored in directory -# pointed by option . +# The scripts in the list must be separated with commas or semicolons. All +# scripts must be stored in directory set by option and +# paths relative to must be entered here. # # The scripts are executed each time a new file is found in incoming # directory (option ) or a file is received via RPC (web-interface, @@ -1618,7 +1627,7 @@ # # In addition to these arguments NZBGet passes all nzbget.conf-options # as environment variables. These variables have prefix "NZBOP_" and -# are written in UPPER CASE. For Example option "ParRepair" is passed as +# are written in UPPER CASE. For , the option "ParRepair" is passed as # environment variable "NZBOP_PARREPAIR". The dots in option names are # replaced with underscores, for example "SERVER1_HOST". For options # with predefined possible values (yes/no, etc.) the values are passed @@ -1699,9 +1708,9 @@ # List of queue scripts to execute on queue events. # -# The scripts in the list must be separated with commas or semicolons. Only -# filenames without path must be used. All scripts must be stored in directory -# pointed by option . +# The scripts in the list must be separated with commas or semicolons. All +# scripts must be stored in directory set by option and +# paths relative to must be entered here. # # The scripts are executed on certain queue events such as adding # a new nzb-file to queue, etc. @@ -1709,7 +1718,7 @@ # Example: DeleteQueueSamples.sh, NzbAddedNotify.py. # # The script can modify the files in download queue (for example -# delete or pause all nfo, sfv, sample files) or do something else. +# delete or pause all .nfo, .sfv, sample files) or do something else. # # INFO FOR DEVELOPERS: # NOTE: This is a short documentation, for more information visit @@ -1718,9 +1727,9 @@ # NZBGet passes following arguments to the queue script as environment # variables: # NZBNA_NZBNAME - name of nzb-group. This name can be used in calls -# to nzbget edit-command using subswitch "-GN name"; +# to nzbget edit-command using the subswitch "-GN name"; # NZBNA_FILENAME - filename of the nzb-file. If the file was added -# from nzb-directory this is the fullname with path. +# from nzb-directory this is the full name with path. # If the file was added via web-interface it contains # only filename without path; # NZBNA_EVENT - describes why the script was called: @@ -1731,6 +1740,8 @@ # (before post-processing); # NZB_DELETED - when nzb is deleted from queue (moved # to history). See NZBNA_DELETESTATUS for details; +# NZB_MARKED - when a history item is marked as good, bad or +# success. See NZBNA_MARKSTATUS for details; # URL_COMPLETED - after an URL download is completed # and the downloaded file was not added to queue # (not nzb-extension, download error, parse @@ -1738,7 +1749,8 @@ # In the future the list of supported events may be # extended. To avoid conflicts with future NZBGet # versions the script must exit if the parameter -# has a value unknown to the script. +# has a value unknown to the script; +# NZBNA_QUEUEDFILE - full filename of the queued (renamed) nzb-file; # NZBNA_DELETESTATUS - delete status info, NZBNA_EVENT=NZB_DELETED: # MANUAL - deleted by user or via API call; # HEALTH - deleted by health check; @@ -1754,6 +1766,10 @@ # SCAN_SKIPPED - downloaded file doesn't have # nzb-extension and was skipped; # SCAN_FAILED - file format error; +# NZBNA_MARKSTATUS - mark status info, NZBNA_EVENT=NZB_MARKED: +# GOOD - marked as good by user or by a script; +# BAD - marked as bad; +# SUCCESS - marked as success; # NZBNA_CATEGORY - category of nzb-file (if assigned); # NZBNA_NZBID - id of the nzb-file. This ID can be used with # calls to nzbget edit-command; @@ -1764,7 +1780,7 @@ # # In addition to these arguments NZBGet passes all nzbget.conf-options # to the script as environment variables. These variables have prefix -# "NZBOP_" and are written in UPPER CASE. For Example option "ParRepair" +# "NZBOP_" and are written in UPPER CASE. For Example, the option "ParRepair" # is passed as environment variable "NZBOP_PARREPAIR". The dots in option # names are replaced with underscores, for example "SERVER1_HOST". For # options with predefined possible values (yes/no, etc.) the values are @@ -1782,6 +1798,9 @@ # # To inform NZBGet about bad download: # echo "[NZB] MARK=BAD"; +# +# To set destination directory (only from event "NZB_DOWNLOADED"): +# echo "[NZB] DIRECTORY=/destination/path/for/this/nzb"; # # Examples of what the script can do: # 1) pausing nzb-file using file-id: @@ -1797,9 +1816,9 @@ # List of rss feed scripts to execute before a rss feed content is processed. # -# The scripts in the list must be separated with commas or semicolons. Only -# filenames without path must be used. All scripts must be stored in directory -# pointed by option . +# The scripts in the list must be separated with commas or semicolons. All +# scripts must be stored in directory set by option and +# paths relative to must be entered here. # # If rss feed has option defined (if not empty) # the scripts defined there override the global option . @@ -1833,6 +1852,15 @@ # with predefined possible values (yes/no, etc.) the values are passed # always in lower case. # +# Return value: NZBGet processes the exit code returned by the script: +# 93 - script successful (status = SUCCESS). +# All other return codes are interpreted as failure (status = FAILURE). +# +# If the script doesn't end with SUCCESS-status the whole content of RSS +# feed is ignored. This is to prevent accidental enqueuing of many +# nzb-files if a feed script unexpectedly terminates before processing +# of the feed. +# # NOTE: This is a short documentation, for more information visit # http://nzbget.net/Extension_scripts. FeedScript= @@ -1843,9 +1871,9 @@ # order defined by this option. Scripts not listed here are executed at # the end in their alphabetical order. # -# The scripts in the list must be separated with commas or semicolons. Only -# filenames without path must be used. All scripts must be stored in directory -# pointed by option . +# The scripts in the list must be separated with commas or semicolons. All +# scripts must be stored in directory set by option and +# paths relative to must be entered here. # # Example: Cleanup.sh, Move.sh. ScriptOrder= @@ -1857,6 +1885,19 @@ # # NOTE: See also options and . ScriptPauseQueue=no + +# Shell overrides for script interpreters. +# +# By default extension scripts are executed as normal programs. The system finds +# an associated interpreter automatically. If for some reason that doesn't work +# properly you can provide shell overrides here. +# +# This option contains a comma separated list of shell overrides per +# file extension. A shell override consists of file extension (starting with +# dot) followed by equal sign and the full path to script interpreter. +# +# Example: .py=/usr/bin/python2;.py3=/usr/bin/python3;.sh=/usr/bin/bash. +ShellOverride= # Minimum interval between calls of queue-scripts (seconds). #