sudo rm -rf app/logs
sudo mkdir app/logs
sudo chmod -R 777 app/logs
This is what I do but the problem is when a file gets created behind the scene by any program, web application or a behat test, the file doesn't automatically get 777 permission assigned to it. They rather get 644. That's my problem. What am I missing?
I've checked these:
You can choose any of the three methods
Use mkdir -m 777 app/logs
Create a script
#!/bin/bash
sudo mkdir -m 777 $1
So exectute ./script_name.sh app/logs