Skip to content

After #1410, configure nginx to serve gzipped files #1427

Open
@pushcx

Description

With propshaft, nginx will read, gzip, and serve our assets. It's a bit wasteful to gzip them for every hit instead of storing them and serving that directly, but it's a feature that Rails decided not to take on.

There's already an example of gzipping in the precomiling (thanks anon stream viewer) and an nginx module to serve them and ubuntu includes this module by default (thanks @nogweii), so this is not much code. Though, warning, I do think that Ruby code is example code rather than something extracted from a working setup, and it uses brotli rather than gzip, so it will need some edits to get running.

To save rework, this depends on #1410 being merged.

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions