- CentOS 7.0 x64 is installed (default install from DigitalOcean Droplet Manager)
- Logged in via ssh key with root privileges
- Using MongoDB as database
Install Remi Collet Repository:
yum install epel-release
rpm -Uvh http://rpms.famillecollet.com/enterprise/remi-release-7.rpm
yum install yum-utils
yum-config-manager --enable remi remi-php56
Install Apache:
yum install httpd
Install PHP and necessary PHP modules:
yum install php php-common php-cli php-pear php-mysqlnd php-pecl-mongo php-gd php-mbstring php-mcrypt php-xml php-bcmath
Install MongoDB
yum install mongodb mongodb-server
Install NodeJs:
yum install nodejs
Install Node Package Manager (NPM):
yum install npm
Install Bower:
npm install -g bower
Install GIT:
yum install git
Install DeltaRPM:
yum install deltarpm
Update CentOS
yum update
Start the Firewall Daemon and enable automatic startup
systemctl start firewalld.service
systemctl enable firewalld.service
Allow HTTP Access through Firewall
firewall-cmd --permanent --zone=public --add-service=http
firewall-cmd --permanent --zone=public --add-service=https
systemctl restart firewalld.service
Start Apache HTTP Daemon and enable automatic startup
systemctl start httpd.service
systemctl enable httpd.service
Start MongoDB and enable automatic startup
systemctl start mongod
systemctl enable mongod
Install Composer and set global launch
curl -sS https://getcomposer.org/installer | php
mv composer.phar /usr/local/bin/composer
Thanks for this guide - it's been very useful.
One thing to add, for those who have selinux enabled - you may need to enable rw access to app/storage, or get a permission denied error when attempting to register:
Error in exception handler: The stream or file "/var/www/learninglocker/app/storage/logs/laravel.log" could not be opened: failed to open stream: Permission denied in /var/www/learninglocker/vendor/monolog/monolog/src/Monolog/Handler/StreamHandler.php:95.
The following worked for me:
yum install policycoreutils-python (if semanage not already installed)
semanage fcontext -a -t httpd_sys_rw_content_t "/var/www/learninglocker/app/storage(/.*)?"
restorecon -Rv /var/www/learninglocker