Before you proceed make sure your server meets the following requirements:
- PHP >= 7.0
- PHP extensions (PDO, SQLite, OpenSSL, Mbstring, Tokenizer, Zip)
- PDO compliant database (SQL / MySQL / PostgreSQL / SQLite)
- Install Canvas by issuing the Composer
create-projectcommand in your terminal:
composer create-project --prefer-dist cnvs/canvas blog
- Set your database credentials in the
Be sure to keep the value of
APP_ENV set to
local for the duration of the installation process.
- Accessing your site in a web browser at this point will present you with the Welcome screen and an Artisan command to finish up the installation. Issue the following command from the project root:
php artisan canvas:install
Files and directories are manipulated both by the CLI user as well as web server. You will need to make sure that you add your user to the
www-data group, or whichever group name your web server runs as:
sudo usermod -a -G www-data userName
The user will need to logout and log back in to see their new group added.
According to the Laravel Documentation, you will need to update your directory permissions:
After installing Laravel, you may need to configure some permissions. Directories within the
bootstrap/cachedirectories should be writable by your web server or Laravel will not run. If you are using the Homestead virtual machine, these permissions should already be set.
The official steps are as follows:
sudo chgrp -R www-data storage/ sudo chgrp -R www-data bootstrap/cache/
Substitute "www-data" for whichever group name your web server runs as. Even though you may have user and group write permissions in these folders,
sudo is required since your account may not be a member of the target group (which fires off an "Operation not permitted" error).
Now that these directories and files belong to the web server's user group, ensure that the group permissions are set:
sudo chmod -R g+w storage/ sudo chmod -R g+w bootstrap/cache/