Breadcrumbs

How to integrate FileCloud with Scality Storage

Administrators can change the FileCloud storage type after FileCloud has been installed but BEFORE any data has been stored. 

  • When changing the storage type from local to Scality, the files and folders that have been already stored in the local storage will not be automatically moved to S3 storage.

  • In this case, the administrator has to manually export files and folders from local storage before changing storage type and manually import them after changing the storage type.


WARNINGS:

  • Only change the FileCloud storage type for new installations.

  • Do not change the FileCloud storage type if FileCloud has been in use and data is already stored.

  • Be very careful when changing the storage path, If done improperly it could lead to data loss. 

  • The Scality Bucket should NEVER be modified outside of FileCloud subsystem

  • Do not add, edit, or modify files directly using Scality tools. Doing so will destabilize your FileCloud installation.


To change the FileCloud storage path from LOCAL to SCALITY:

1. Enable Scality object storage

NOTES:

Although FileCloud does not have an explicit connector for Scality, the Amazon S3 connector can be used.

In this step you will need to access WWWROOT. It is typically located at: 

Windows

Linux

c:\xampp\htdocs

/var/www/html

To enable Scality storage as the backend:

  1.  To make sure that your server does not have any time variations, set up the time on your server to be synchronized.

    1. Configure an authoritative time server in Windows Server

    2. Synchronize Time with NTP in Linux

  2. Open the following file for editing:

    WWWROOT/config/cloudconfig.php
    
  3. Find the following line:

    define("TONIDOCLOUD_STORAGE_IMPLEMENTATION", "local");
    
  4. Change it to this line:

    define("TONIDOCLOUD_STORAGE_IMPLEMENTATION", "amazons3");
    
  5. Save and close the file.

  6. Find the following file:

    WWWROOT/config/amazons3storageconfig-sample.php
    
  7. Rename it to:

    WWWROOT/config/amazons3storageconfig.php
    

https://fileclouddocs.atlassian.net/wiki/s/1623602073/6452/05f502871a457750e4d6a5e1f585bce5603b62b2/_/images/icons/emoticons/lightbulb_on.png  Nothing needs to be added or edited in amazons3storageconfig.php

2. Configure Credentials

To configure Digital Ocean S3 Credentials:

  1. In the FileCloud admin portal's left navigation bar, scroll down and click Settings. Then, on the Settings navigation page, click Storage  StorageIcon.png .
    The Managed Storage settings page opens by default.

  2. Type in or select the settings for your environment. See the table below for information about each setting.

    S3Generic.png
  3. Click Save S3 Settings.

Field

Description

S3 Key

This is your Scality authentication key.

S3 Secret

This is your Scality authentication secret.

Use IAM role

When checked, the S3 Key and S3 Secret fields disappear and the IAM role is used to connect to the S3 bucket.

S3 Bucket Name

Provide a bucket name. The bucket should be new (in some circumstance, previously used bucket in FileCloud could be used).

It is very important that the S3 bucket is never modified outside of the FileCloud subsystem,

the bucket name is case sensitive make sure you are using the exact name of the bucket.

S3 Storage Folder

Optional: All files will be stored inside this root storage folder (Will be created automatically).

S3 Region

Optional: Provide the region string.

S3 End Point URL

This is the S3 endpoint. note that for each region there is a specific Endpoint URL.

  1. To fill in the remainder of the settings, see Setting up FileCloud Managed S3 Storage.



blankSpacer.png

Troubleshooting:

How to Correct Issues with Image Previews

If you are having problems in previewing images, you should add a line to the .htaccess file.

To add a line to the .htaccess file:

  1. Open the following file:

    1. Windows:  C:\xampp\htdocs\.htaccess

    2. Linux: /var/www/html/.htaccess

  2. Add the following line:

    Header set Content-Security-Policy: "default-src 'self' *.live.com; style-src 'unsafe-inline' 'self';script-src 'unsafe-inline' 'unsafe-eval' 'self';font-src 'self' data:;img-src 'self' *.live.com  data: *.duosecurity.com *.scality.com"
    
How to Correct Issues with playing mp4 videos

If you are having problems in playing  mp4 videos, you should add a line to the .htaccess file.

To add a line to the .htaccess file:

  1. Open the following file:

    1. Windows:  C:\xampp\htdocs\.htaccess

    2. Linux: /var/www/html/.htaccess

  2. Add the following line:

    Header set Content-Security-Policy: "default-src 'self' *.live.com *.scality.com; style-src 'unsafe-inline' 'self';script-src 'unsafe-inline' 'unsafe-eval' 'self';font-src 'self' data:;img-src 'self' *.live.com  data: *.duosecurity.com *.scality.com"