add application protocol attribut for HTTP

This commit is contained in:
Marko Oldenburg 2020-10-20 15:45:33 +02:00
parent 16f8bdbce8
commit dc0c072ab5
3 changed files with 14 additions and 12 deletions

View File

@ -55,6 +55,7 @@ sub backupToStorage_Initialize {
'bTS_Host '
. 'bTS_User '
. 'bTS_Path '
. 'bTS_Proto:https,http '
. 'bTS_Type:Nextcloud';
$hash->{parseParams} = 1;
@ -175,7 +176,7 @@ sub backupToStorage_Initialize {
],
"release_status": "devepolment",
"license": "GPL_2",
"version": "v1.0.1",
"version": "v1.1.0",
"author": [
"Marko Oldenburg <fhemsupport@cooltux.net>"
],

View File

@ -1,2 +1,2 @@
UPD 2020-10-19_09:19:38 6100 FHEM/98_backupToStorage.pm
UPD 2020-10-19_19:31:51 15811 lib/FHEM/backupToStorage.pm
UPD 2020-10-20_15:44:56 6132 FHEM/98_backupToStorage.pm
UPD 2020-10-20_15:44:23 16005 lib/FHEM/backupToStorage.pm

View File

@ -345,6 +345,7 @@ sub PushToStorage {
$subprocess->{path} = AttrVal( $name, 'bTS_Path', '' );
$subprocess->{backupfile} = $backupFile;
$subprocess->{fileNameAtStorage} = $fileNameAtStorage;
$subprocess->{proto} = AttrVal( $name, 'bTS_Proto', 'https' );
my $pid = $subprocess->run();
@ -441,7 +442,7 @@ sub ExecuteNCupload {
$command .= ' -s -u ';
$command .= $subprocess->{user} . ':' . $subprocess->{pass};
$command .= ' -T ' . $subprocess->{backupfile};
$command .= ' "https://';
$command .= ' "' . $subprocess->{proto} . '://';
$command .= $subprocess->{host};
$command .= '/remote.php/dav/files/';
$command .= $subprocess->{user};