~zacbrown/nginx-static-site-container

643a7e623892a4f239fdc4c11aa207a6ebab5736 — Zac Brown 9 months ago 170e90e main
Add cache control headers for static assets.

Signed-off-by: Zac Brown <git@zacbrown.org>
1 files changed, 6 insertions(+), 1 deletions(-)

M nginx.non-root.conf
M nginx.non-root.conf => nginx.non-root.conf +6 -1
@@ 50,12 50,17 @@ http {
            default_type application/json;
            return 200 '{"response_status":200,"data":"alive"}';
        }

        location /nginx_status {
            access_log off;
            stub_status on;
            allow 127.0.0.1;
            deny all;
        }
    }

        location ~* \.(css|png|jpg|jpeg|gif|svg|ico|woff|woff2|ttf)$ {
            expires max;
            add_header Cache-Control "public, no-transform";
        }
    }
}