Search code examples
symfonybundleassets

Symfony2 assests in bundles directory 404 error


After doing some research, I still cannot understand why my assets in the bundles folder return 404 errors when I try to reach them.

I can see the files on the server, but when I try to reach them, symfony returns a 404 error.

For example, I have this file on the server : web/bundles/aluser/images/li-plus.png, but trying to access it with https://my-site.com/bundles/aluser/images/li-plus.png returns a 404 error. But on the other hand I can access files in https://my-site.com/images/li-plus.png for example.

I did the assets install and dump commands, cleared the cache but no results.

Thank you.


Solution

  • Thank you all for your answers,

    they pointed me in the right direction (a problem with the server) : I did a asset install and dump commands with the root user of the server, all files created were then associated to this root user, and apache wouldn't serve them anymore.

    After a chown, everything was working again. Thanks again :)