Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7540863
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T07:44:38+00:00 2026-05-30T07:44:38+00:00

I check the headers on my production server as curl –head -H Accept-Encoding: gzip

  • 0

I check the headers on my production server as

    curl --head -H "Accept-Encoding: gzip" http://foo.heroku.com/assets/mobile.js

and I get back the following headers which suggest RAILS is not setting the cachecontrol headers.

HTTP/1.1 200 OK
Server: nginx/0.7.67
Date: Wed, 22 Jun 2011 12:01:55 GMT
Content-Type: application/javascript
Connection: keep-alive
Content-Md5: efb90436a465f8a73efb467109f745f3
Cache-Control: no-cache
Last-Modified: Wed, 22 Jun 2011 11:46:04 GMT
Etag: "efb90436a465f8a73efb467109f745f3"
X-Ua-Compatible: IE=Edge,chrome=1
X-Runtime: 0.001258
X-Content-Digest: 6493f457e9550773761bb1c2c52ec4cb44a19c19
X-Rack-Cache: stale, valid, store
X-Varnish: 164373614
Age: 0
Via: 1.1 varnish
Content-Encoding: gzip

I’d like to get heroku’s varnish cache caching the assets and only refreshing on git push. Any ideas on how to get this?

Brad

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-30T07:44:40+00:00Added an answer on May 30, 2026 at 7:44 am

    You have to add this in your environment/production.rb:

    config.serve_static_assets = true
    config.static_cache_control = "public, max-age=172800"
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a requirement that I want to check the request headers and according
Please check out http://rainsongmanchesters.net/news.htm and notice the black strip above the header image. Now
Well this one freaks me out. I used a Http Header check tool to
On a production Linux box without development tools installed (e.g. no headers, no gcc)
How can I use HTTP headers to control when my cache should be updated?
I am having check box in the column header. The function of this is
In the header of my page I have a conditional statement to check if
In django how to check whether any entry exists for a query sc=scorm.objects.filter(Header__id=qp.id) This
Check out this test: [TestFixture] public class Quick_test { [Test] public void Test() {
check this out: template <class T> class Test: public T { public: void TestFunc()

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.