Showing results for 
Search instead for 
Did you mean: 

pub/static ownership change

pub/static ownership change

Why is Magento 2.0.2 CE modifying the ownership of *any* file? This is a *very* bad practice - it should always be using proper inheritance.



- The web root folder "html" is set to "uldev:www-data"

- The root folders of the project, along with all files pushed or created at install are set properly to "uldev:www-data"

- nginx is running traditional on Ubunto



- running the site for the first time (from the web)

- changing from development mode to production (via CLI as user uldev who is a member of www-data)

- deploying the static files (via CLI)


pub/static/frontend/Magento/luma/en_US is created and populated - all good.



- the ownership of the files that are created are set to "root:uldev"

- Within the web root there should *never* be a folder with the user of "root" - security people!

- And the group should always match that set in the root of the project and inherited throughout. For that matter the owner should as well.