45d165749f
Move MinIO from minio.localhost to minio.fizzy.localhost, which makes it same-site with the app, so the CORS redirect succeeds. The service worker fetches Active Storage URLs with `mode: "cors"` so it can inspect response sizes for offline caching. Active Storage's redirect controller returns a 302 to the MinIO presigned URL. When that redirect crosses site boundaries (from fizzy.localhost to minio.localhost), the browser sets the Origin header to "null" on the redirected request per the Fetch spec, which fails the CORS check and produces net::ERR_FAILED.
34 lines
1.5 KiB
YAML
34 lines
1.5 KiB
YAML
test:
|
|
service: Disk
|
|
root: <%= Rails.root.join("tmp/storage/files") %>
|
|
|
|
local:
|
|
service: Disk
|
|
root: <%= Rails.root.join("storage", Rails.env, "files") %>
|
|
|
|
devminio:
|
|
service: S3
|
|
bucket: fizzy-dev-activestorage
|
|
endpoint: "http://minio.fizzy.localhost:39000"
|
|
force_path_style: true
|
|
request_checksum_calculation: when_required # default is when_supported with CRC64NVME checksum which FlashBlade doesn't support
|
|
response_checksum_validation: when_required # default is when_supported with CRC64NVME checksum which FlashBlade doesn't support
|
|
region: us-east-1 # default region required for signer
|
|
access_key_id: minioadmin
|
|
secret_access_key: minioadmin
|
|
|
|
# We have "development", "staging", and "production" buckets configured. Note that we don't have a
|
|
# "beta" bucket. (As of 2025-06-01.)
|
|
<% pure_env = Rails.env.beta? ? "production" : Rails.env %>
|
|
purestorage:
|
|
service: S3
|
|
bucket: fizzy-<%= pure_env %>-activestorage
|
|
endpoint: "https://storage.basecamp.com"
|
|
ssl_verify_peer: false # FIXME: using self-signed cert internally
|
|
force_path_style: true
|
|
request_checksum_calculation: when_required # default is when_supported with CRC64NVME checksum which FlashBlade doesn't support
|
|
response_checksum_validation: when_required # default is when_supported with CRC64NVME checksum which FlashBlade doesn't support
|
|
region: us-east-1 # default region required for signer
|
|
access_key_id: <%= ENV["ACTIVE_STORAGE_ACCESS_KEY_ID"] %>
|
|
secret_access_key: <%= ENV["ACTIVE_STORAGE_SECRET_ACCESS_KEY"] %>
|