Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

activestorage-tencent_cos

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

activestorage-tencent_cos

  • 0.0.2
  • Rubygems
  • Socket score

Version published
Maintainers
1
Created
Source

ActiveStorage::Service::TencentCOSService

Active Storage Serivce for Tencent COS

Notes

It is important to note that this library is still in early stages and is currently being implemented according to my needs

  • only public read bucket is support(HTTP caching purpose)
  • direct upload only
  • delete variants have not yet been implemented

Usage

Enable CORS on your bucket(for direct upload) https://cloud.tencent.com/document/product/436/13318

Add to your Gemfile

gem 'activestorage-tencent_cos'

Edit config/storage.yml

tencent:
  service: TencentCOS
  secret_id: your_secret_id
  secret_key: your_secret_key
  app_id: your_app_id
  bucket: your_bucket
  region: ap-guangzhou # https://cloud.tencent.com/document/product/436/6224
  endpoint: https://assets.example.com # your cdn url
  max_age: 3600 # http cache time

Edit config/environments/production.rb

config.active_storage.service = :tencent

Tips

Use cdn url directly

<%= image_tag book.cover.service_url %>

FAQs

Package last updated on 12 Nov 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc