After running: $ ./manage.py migrate
I am getting the following error:
-bash: ./manage.py: Permission denied
Trying to run a migration after making a change in the DB. Any advice would be really appreciated.
The PermissionError: [errno 13] permission denied error occurs when you try to access a file from Python without having the necessary permissions. To fix this error, use the chmod or chown command to change the permissions of the file so that the right user and/or group can access the file.
Permission denied simply means the system is not having permission to write the file to that folder. Give permissions to the folder using "sudo chmod 777 " from terminal and try to run it.
You need to make manage.py executable to excecute it. Do chmod +x manage.py
to make it excecutable. Alternately you can do python manage.py <cmd>
instead.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With