0

Issue

It doesn't appear that my merged/minified files are being updated when changed whilst in Production Mode. For example, I made a change to this file:

app/design/frontend/Theme/theme_child/web/css/styles.css

But even after I run the following, the styling isn't taking effect:

bin/magento setup:di:compile
bin/magento setup:static-content:deploy en_GB en_US
bin/magento cache:flush

I even hit the Flush Javascript/CSS Cache button on the backend.

Question

Am I missing a step? Is this a known "gremlin"? Could some of the cached files not be clearing as expected? What folder can I rm -rf to manually purge them so they can be re-deployed?

Notes:

  • The changes do take affect on my Dev Server
  • It's not my browsers cache
  • I'm not using a CDN
Craig
  • 2,650
  • 3
  • 15
  • 37

3 Answers3

0

You can run this:

rm -rf var/cache/* var/page_cache/* var/session/* var/view_preprocessed/pub/static/* pub/static/frontend/* generated/code/*

Maybe another cache like Varnish? After your command you should see changes maybe try change styling in _theme.less its alwayes loaded last one , maybe changes from style.less was overrided by different file.

BartZalas
  • 1,757
  • 12
  • 23
0

Try to :

  1. clean the content of pub/static/ without the .htaccess, once again the content and NOT the folder.

  2. php bin/magento c:c && php bin/magento c:f. //cache:clean and cache:flush

  3. php bin/magento setup:static-content:deploy -f

  4. clean the browser cache.

Good luck.

PЯINCƎ
  • 11,669
  • 3
  • 25
  • 80
0

you can run the production mode set command again.

bin/magento deploy:mode:set production