From 09eb01aaafc7e196f2b903cf315e4db89b4a2a83 Mon Sep 17 00:00:00 2001 From: KodeStar Date: Thu, 3 Aug 2017 13:34:02 +0100 Subject: [PATCH] Abstracted to allow multiple storage containers --- appinfo/info.xml | 12 ++++++------ lib/Controller/BackblazeController.php | 4 ++-- lib/Controller/PageController.php | 2 +- lib/ObjectStore/Backblaze.php | 4 ++-- lib/ObjectStore/Hubic.php | 22 ++++++++++++++++++++++ lib/Service/BackblazeService.php | 2 +- 6 files changed, 34 insertions(+), 12 deletions(-) create mode 100644 lib/ObjectStore/Hubic.php diff --git a/appinfo/info.xml b/appinfo/info.xml index 728a23c..fb69391 100644 --- a/appinfo/info.xml +++ b/appinfo/info.xml @@ -1,9 +1,9 @@ - objectstoragebackblaze - Object Storage Backblaze - Backblaze B2 integration for primary storage + objectstorageapp + Object Storage App + Object storage integration for primary storage agpl Chris Hunt @@ -12,14 +12,14 @@ files integration tools - https://github.com/linuxserver/objectstoragebackblaze/issues + https://github.com/linuxserver/objectstorageapp/issues - Object Storage Backblaze - objectstoragebackblaze.page.index + Object Storage App + objectstorageapp.page.index diff --git a/lib/Controller/BackblazeController.php b/lib/Controller/BackblazeController.php index 8e36eae..805260b 100644 --- a/lib/Controller/BackblazeController.php +++ b/lib/Controller/BackblazeController.php @@ -1,9 +1,9 @@ array( + 'class' => 'OCA\\ObjectStorageBackblaze\\ObjectStore\\Backblaze', + 'arguments' => array( + 'clientId' => 'username', + 'applicationId' => 'Secr3tPaSSWoRdt7', + // the container to store the data in + 'bucket' => 'nextcloud', + ), +), + */ + +namespace OCA\ObjectStorageApp\ObjectStore; + +use OCP\Files\ObjectStore\IObjectStore; +use OCP\Files\StorageAuthException; +use OCP\Files\StorageNotAvailableException; + +class Hubic implements IObjectStore { + +} diff --git a/lib/Service/BackblazeService.php b/lib/Service/BackblazeService.php index c6222b1..fac4aa0 100644 --- a/lib/Service/BackblazeService.php +++ b/lib/Service/BackblazeService.php @@ -1,5 +1,5 @@