[Solved] file_put_contents(/bootstrap/cache/packages.php): failed to open stream: Permission denied
Updated: 17th February 2023Tags: laravel php ubuntu
For example we have our folder in /etc/nginx/sites-available/example.com
And to make virtual symlink folder here /etc/nginx/sites-enabled
we run this
sudo ln -s /etc/nginx/sites-available/example.com /etc/nginx/sites-enabled/
ls -Slh
-S will sort files by size
-l long listing
-h will make the output human-readable
-r will reverse the output
Edit file ~/.bash_aliases
nano ~/.bash_aliases
For example I make alias a
. So when I press a
it will produce php artisan tinker
Here file ~/.bash_aliases
alias a='php artisan tinker'
Load aliases immediately
source ~/.bash_aliases
ps aux --sort=-%mem | awk 'NR<=800{print $0}'
ps -eo pid,lstart,cmd
To run some command in background, so you can close terminal, type the following:
nohup command-with-options &
After installing laravel you MUST change some folder permissions.
sudo chmod 755 -R laravel_app
sudo chmod -R o+w laravel_app/storage
sudo chmod -R o+w laravel_app/bootstrap/cache