mirror of
https://github.com/Sonarr/Sonarr.git
synced 2024-12-16 11:37:58 +02:00
Connect to SAB over SSL (optional)
New: Ability to connect to SABnzbd over SSL
This commit is contained in:
parent
89c2ff6107
commit
938b5f1ae3
@ -128,6 +128,13 @@ public SabPriorityType SabOlderTvPriority
|
|||||||
set { SetValue("SabOlderTvPriority", value); }
|
set { SetValue("SabOlderTvPriority", value); }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public bool SabUseSsl
|
||||||
|
{
|
||||||
|
get { return GetValueBoolean("SabUseSsl", false); }
|
||||||
|
|
||||||
|
set { SetValue("SabUseSsl", value); }
|
||||||
|
}
|
||||||
|
|
||||||
public String DownloadedEpisodesFolder
|
public String DownloadedEpisodesFolder
|
||||||
{
|
{
|
||||||
get { return GetValue(ConfigKey.DownloadedEpisodesFolder.ToString()); }
|
get { return GetValue(ConfigKey.DownloadedEpisodesFolder.ToString()); }
|
||||||
@ -162,7 +169,7 @@ public int Retention
|
|||||||
|
|
||||||
public DownloadClientType DownloadClient
|
public DownloadClientType DownloadClient
|
||||||
{
|
{
|
||||||
get { return GetValueEnum("DownloadClient", DownloadClientType.Sabnzbd); }
|
get { return GetValueEnum("DownloadClient", DownloadClientType.Blackhole); }
|
||||||
|
|
||||||
set { SetValue("DownloadClient", value); }
|
set { SetValue("DownloadClient", value); }
|
||||||
}
|
}
|
||||||
|
@ -18,6 +18,7 @@ public interface IConfigService
|
|||||||
String SabTvCategory { get; set; }
|
String SabTvCategory { get; set; }
|
||||||
SabPriorityType SabRecentTvPriority { get; set; }
|
SabPriorityType SabRecentTvPriority { get; set; }
|
||||||
SabPriorityType SabOlderTvPriority { get; set; }
|
SabPriorityType SabOlderTvPriority { get; set; }
|
||||||
|
Boolean SabUseSsl { get; set; }
|
||||||
String DownloadedEpisodesFolder { get; set; }
|
String DownloadedEpisodesFolder { get; set; }
|
||||||
bool UseSeasonFolder { get; set; }
|
bool UseSeasonFolder { get; set; }
|
||||||
string SeasonFolderFormat { get; set; }
|
string SeasonFolderFormat { get; set; }
|
||||||
|
@ -221,7 +221,10 @@ public virtual string Test(string host, int port, string apiKey, string username
|
|||||||
|
|
||||||
private string GetSabRequest(string action)
|
private string GetSabRequest(string action)
|
||||||
{
|
{
|
||||||
return string.Format(@"http://{0}:{1}/api?{2}&apikey={3}&ma_username={4}&ma_password={5}",
|
var protocol = _configService.SabUseSsl ? "https" : "http";
|
||||||
|
|
||||||
|
return string.Format(@"{0}://{1}:{2}/api?{3}&apikey={4}&ma_username={5}&ma_password={6}",
|
||||||
|
protocol,
|
||||||
_configService.SabHost,
|
_configService.SabHost,
|
||||||
_configService.SabPort,
|
_configService.SabPort,
|
||||||
action,
|
action,
|
||||||
|
@ -96,4 +96,25 @@
|
|||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div class="control-group">
|
||||||
|
<label class="control-label">Use SSL</label>
|
||||||
|
|
||||||
|
<div class="controls">
|
||||||
|
<label class="checkbox toggle well">
|
||||||
|
<input type="checkbox" name="sabUseSsl" class="x-ssl"/>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
<span>Yes</span>
|
||||||
|
<span>No</span>
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<div class="btn btn-primary slide-button"/>
|
||||||
|
</label>
|
||||||
|
|
||||||
|
<span class="help-inline-checkbox">
|
||||||
|
<i class="icon-nd-form-info" title="Connect to SABnzbd over SSL"/>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<br/>
|
<br/>
|
||||||
|
|
||||||
<div class="row advanced-setting">
|
<div class="row advanced-setting">
|
||||||
<div class="span12" id="quality-size"/>
|
<div class="span12" id="quality-size"/>
|
||||||
</div>
|
</div>
|
||||||
|
Loading…
Reference in New Issue
Block a user