Closed Bug 1906959 Opened 8 months ago Closed 7 months ago

Facilitate storage buckets behind a CDN

Categories

(Tecken :: General, task, P2)

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: sven, Assigned: sven)

References

(Blocks 1 open bug)

Details

Attachments

(1 file, 1 obsolete file)

In GCP, we want to put a CDN in front of of the Cloud Storage bucket, since this will drastically reduce egress costs for us, regardless of whether we actually cache symbol files in the CDN or not. This means we need a way to configure the public URL for each bucket. The URL for the CDN usually does not include the bucket name, so we can't simply provide the CDN URL as the backend URL; the current code parses the bucket name from the backend URL.

I'm tempted to add some way of providing structured configuration for each backend, e.g. by accepting a JSON object for each backend, or even by adding the backend configuration to the database. However, it requires far fewer code changes to accept the public URL as a query parameter to the backend URL, e.g. https://storage.googleapis.com/my-bucket?public_url=https://cdn.symbols.mozilla.org/.

To be able to test the CDN setup in the local development environment, we can add a simple nginx container that reverse-proxies to the storage emulator to our docker-compose configuration.

Assignee: nobody → sven
Blocks: 1687804
Status: NEW → ASSIGNED
Priority: -- → P2
Attachment #9411989 - Attachment is obsolete: true
Depends on: 1908868

We decided to switch to structured configuration for storage backends, so we no longer need the hack of passing the public URL as a query parameter to a URL.

Everything up to this point went out in bug #1910917 just now.

Sven: Is there anything left in this bug to do?

Flags: needinfo?(sven)

This isn't used in AWS yet. We'll verify this as part of the validation of the new environment, so I think we can close this bug.

Status: ASSIGNED → RESOLVED
Closed: 7 months ago
Flags: needinfo?(sven)
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: