heroku / heroku-buildpack-ember-cli

A Heroku buildpack for ember-cli apps; powers dashboard.heroku.com
58 stars 15 forks source link

static.json not overriding #3

Closed dbinetti closed 8 years ago

dbinetti commented 8 years ago

It does not appear that my static.json file is being respected by the build pack.

Steps:

  1. Include the following static.son in the root directory:
{
  "root": "dist/",
  "https_only": false,
  "clean_urls": true,
  "routes": {
    "/**": "index.html"
  },
  "headers": {
    "/**": {
      "Cache-Control": "private, no-store, no-cache, must-revalidate, proxy-revalidate",
      "Pragma": "no-cache",
      "Expires": "Sat, 05 Nov 1955 00:00:00 PST",
      "Strict-Transport-Security": "max-age=86400; includeSubDomains;",
      "X-Download-Options": "noopen",
      "X-Content-Type-Options": "nosniff",
      "X-Frame-Options": "SAMEORIGIN",
      "X-XSS-Protection": "1; mode=block"
    },
    "/assets/**": { "Cache-Control": "public, max-age=512000" },
    "/robots.txt": { "Cache-Control": "public, max-age=512000" },
    "/crossdomain.xml": { "Cache-Control": "public, max-age=512000" }
  }
}
  1. Deploy
  2. Open a bash shell on the production instance, and examine the static.json in the compiled slug. Notice that the https_only flag is still true
dbinetti commented 8 years ago

Yep, works great. Well done (meaning: Done. Fast.)