3

I want to put my store on production mode, I use this command on ssh:

php bin/magento deploy:mode:set production 

And I have this output:

Enabling maintenance mode
Config "dev/debug/debug_logging = 0" has been saved.
Starting compilation
Something went wrong while compiling generated code. See the error log for details.
Disabling maintenance mode
Command returned non-zero exit code:
`/opt/cpanel/ea-php72/root/usr/bin/php -f /home/store/public_html/m2/bin/magento setup:di:compile`

I check the system.log and there I have this error:

[2019-07-18 08:03:53] main.CRITICAL: Unable to get content for 'frontend/theme/store/en_US/Magento_Swatches/css/swatches.css' {"exception":"[object] (Magento\\Framework\\View\\Asset\\File\\NotFoundException(code: 0): Unable to get content for 'frontend/theme/store/en_US/Magento_Swatches/css/swatches.css' at /home/store/public_html/m2/vendor/magento/framework/View/Asset/File.php:187)"} []

In my custom theme is nothing related to the Magento_Swatches and much more I don't use Swatches.

What can I do to can enable the Production Mode?

Thank you

  • Try skip compilation php bin/magento deploy:mode:set production --skip-compilation – Shoaib Munir Jul 18 at 9:12
2

You can try editing your env.php file inside the folder:

app → etc

And set MAGE_MODE to production

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.