Magento mode switch
The Magento application has three modes of operation that make it convenient for you to deploy it in a development or production environment.
Not only do these modes enable you to change Magento application behavior, switching between them using the
magento deploy:mode:set command also sets file system permissions automatically.
To switch modes:
- Log in as, or switch to, the Magento file system owner.
- Change to the
<your Magento install dir>/bindirectory.
magento deploy:mode:setcommand as summarized in the following table.
Mode Command File system permissions developer
magento deploy:mode:set developer
Directories: 770 (owner and group have full control, all others have no access)
Files: 660 (owner and group have write access, all others have no access)</td> </tr>
magento deploy:mode:set production [--keep-generated]
Directories: 750 (owner has full control, group has read and execute access, all others have no access)
Files: 640 (owner has write access, group has read-only access, all others have no access)</td> </tr> </tbody> </table>