The project is in a healthy, maintained state
Providing Storj S3 gateway support for activestorage-storj gem
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Runtime

~> 1.48
~> 7.0, >= 7.0.4
 Project Readme

ActiveStorage-Storj-S3

ActiveStorage-Storj-S3 is a ruby gem extension for activestorage-storj gem to provide Storj S3 Compatible Gateway support for some ActiveStorage features, e.g. direct upload which requires S3 presigned URL.

Requirements

Installation

  • Add this line to your Rails application's Gemfile:

    gem 'activestorage-storj-s3', '~> 1.0'

    And then execute:

    $ bundle install
  • Modify Storj configuration in config/storage.yml:

    storj:
      service: storj_s3   # change from "storj" to "storj_s3"
      ...
      # provide the Storj S3 gateway credentials
      s3_gateway:
        access_key_id: ""
        secret_access_key: ""
        endpoint: ""
        region: global

    The rest configurations are same as in activestorage-storj gem.

Running the Tests

  • Create configurations.yml file in test/dummy/config/environments/service folder, or copy the existing configurations.example.yml as configurations.yml.

  • Provide Storj configurations for both storj and storj_public services in configurations.yml:

    storj:
      service: storj_s3
      access_grant: ""
      bucket: ""
      auth_service_address: auth.storjshare.io:7777
      link_sharing_address: https://link.storjshare.io
      s3_gateway:
        access_key_id: ""
        secret_access_key: ""
        endpoint: ""
        region: global
    
    storj_public:
      service: storj_s3
      access_grant: ""
      bucket: ""
      auth_service_address: auth.storjshare.io:7777
      link_sharing_address: https://link.storjshare.io
      s3_gateway:
        access_key_id: ""
        secret_access_key: ""
        endpoint: ""
        region: global
      public: true
  • Run the tests:

    $ bin/test