mirror of
https://github.com/we-promise/sure.git
synced 2026-04-19 03:54:08 +00:00
add custom s3 support storage config option (#239)
Options are documented here including an example on how to set a custom endpoint: https://guides.rubyonrails.org/active_storage_overview.html#s3-service-amazon-s3-and-s3-compatible-apis
This commit is contained in:
@@ -107,3 +107,12 @@ BRAND_NAME=
|
||||
# CLOUDFLARE_SECRET_ACCESS_KEY=
|
||||
# CLOUDFLARE_BUCKET=
|
||||
#
|
||||
# Generic S3
|
||||
# ==========
|
||||
# ACTIVE_STORAGE_SERVICE=generic_s3 <- Enables Generic S3 storage
|
||||
# GENERIC_S3_ACCESS_KEY_ID=
|
||||
# GENERIC_S3_SECRET_ACCESS_KEY=
|
||||
# GENERIC_S3_REGION=
|
||||
# GENERIC_S3_BUCKET=
|
||||
# GENERIC_S3_ENDPOINT=
|
||||
# GENERIC_S3_FORCE_PATH_STYLE= <- defaults to false
|
||||
|
||||
@@ -22,4 +22,12 @@ cloudflare:
|
||||
bucket: <%= ENV['CLOUDFLARE_BUCKET'] %>
|
||||
request_checksum_calculation: "when_required"
|
||||
response_checksum_validation: "when_required"
|
||||
|
||||
|
||||
generic_s3:
|
||||
service: S3
|
||||
access_key_id: <%= ENV["GENERIC_S3_ACCESS_KEY_ID"] %>
|
||||
secret_access_key: <%= ENV["GENERIC_S3_SECRET_ACCESS_KEY"] %>
|
||||
region: <%= ENV["GENERIC_S3_REGION"] %>
|
||||
bucket: <%= ENV["GENERIC_S3_BUCKET"] %>
|
||||
endpoint: <%= ENV["GENERIC_S3_ENDPOINT"] %>
|
||||
force_path_style: <%= ActiveModel::Type::Boolean.new.cast(ENV.fetch("GENERIC_S3_FORCE_PATH_STYLE", "false")) %>
|
||||
|
||||
Reference in New Issue
Block a user