Closed Bug 1041151 Opened 10 years ago Closed 10 years ago

nginx eats CORS headers for zip files

Categories

(Cloud Services :: Operations: Marketplace, task)

task
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: twiss, Assigned: jason)

Details

User Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:33.0) Gecko/20100101 Firefox/33.0 (Beta/Release) Build ID: 20140702085013 Steps to reproduce: A month ago I sent a pull request (https://github.com/mozilla/zamboni/pull/2232/files) concerning adding CORS headers to /downloads/file/*.zip requests. Without nginx it works, but nginx apparently eats those headers. For the similar pull request for /app/*/manifest.webapp files (https://github.com/mozilla/zamboni/pull/2228/files), it *does* work. I found a nginx.conf file (https://gist.github.com/cvan/7794203), but it's outdated and behaves different yet again; it eats the CORS headers for both urls. ### Actual steps to reproduce: > $ curl -I https://marketplace.allizom.org/downloads/file/253911/whatsapp-firefox-os-1.0.11.zip Or: > $ curl -I https://marketplace.firefox.com/downloads/file/253821/codebreaker-1.2.zip Actual results: There's no Access-Control-Allow-Origin: * Expected results: It should be there.
I found an nginx.conf (https://github.com/mozilla/marketplace-docs/blob/ab249b80d52d1b4be1a513644ea937fd91b3488d/docs/config/nginx.conf) which worksforme locally. Is that what's running on marketplace.allizom.org/firefox.com? And just to be sure, is either of those servers actually up to date to https://github.com/mozilla/zamboni/commit/c2c4c6a6eb67ec6a937330804299a7a5adef847c ?
Assignee: nobody → server-ops-amo
Component: General → Server Operations: AMO Operations
Product: Marketplace → mozilla.org
QA Contact: oremj
Version: 2014-Q3 → other
Assignee: server-ops-amo → jthomas
Added https://github.com/mozilla-services/svcops-puppet/commit/a36c1490cce9ed9046ab30fd332c26b4a13bd154 to -dev. λ master ~ → curl -I https://marketplace-dev.allizom.org/downloads/file/218668/bien-so-xe-1.0.0.zip HTTP/1.1 200 OK Server: nginx Content-Type: application/zip Date: Tue, 22 Jul 2014 14:34:17 GMT Access-Control-Allow-Origin: * Accept-Ranges: bytes Etag: "f4cbccfaf686a2852082d6340d004f41a535834d592982cd87bfb41953b1f1e5" Via: Moz-zlb10 Connection: keep-alive Set-Cookie: lang="en-US\054"; Path=/ Last-Modified: Mon, 07 Jul 2014 23:18:27 GMT Content-Length: 290150
Status: UNCONFIRMED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
This will land on stage and prod later today.
Confirmed. Thanks a lot!
Component: Server Operations: AMO Operations → Operations: Marketplace
Product: mozilla.org → Mozilla Services
You need to log in before you can comment on or make changes to this bug.