(This is an updated version of my own tutorial for EE2.)
-
Create your droplet. Name it, select your size and location, then hit the Applications tab and select (as of this writing) "LAMP on 14.04". Add your SSH key if you want, and submit.
-
Make sure mod_rewrite is enabled, with
a2enmod rewrite
. -
If you like, increase PHP's
upload_max_filesize
andpost_max_filesize
values by editing the php.ini file, with this:nano /etc/php/7.0/apache2/php.ini
-
Give Apache a restart:
service apache2 restart
-
Run
mysql_secure_installation
. It will ask for the initial mysql root password which is saved in/root/.digitalocean_password
. -
Log in to MySQL:
mysql -u root -p
(It will prompt you for your password.) -
Create a new user, so we aren't using root all the time:
CREATE USER [NEW USERNAME]@'%' IDENTIFIED BY '[NEW PASSWORD]';
-
Grant the new user full access:
GRANT ALL PRIVILEGES ON * . * TO '[NEW USERNAME]'@'%';
-
FLUSH PRIVILEGES;
and exit out of MySQL. -
Restart MySQL:
service mysql restart
-
Make sure .htaccess is enabled for rewrites. Open the Apache config file:
sudo nano /etc/apache2/sites-available/000-default.conf
(In my limited experience, this file name is subject to change as new versions of Ubuntu are realeased, so if Nano opens an empty file, that ain't it.) -
Add this directory statement and save:
<Directory /var/www/> Options Indexes FollowSymLinks MultiViews AllowOverride All Order allow,deny allow from all </Directory>
-
Give Apache a restart:
service apache2 restart
-
Your web root is at
/var/www/html
, you can now upload EE's files via SFTP. -
Create the DB for EE. Log back in to MySQL:
mysql -u [your new user's name] -p
-
Enter
CREATE DATABASE [new DB name];
. Exit MySQL. -
You can now go to your droplet's IP address
/admin.php
and run EE's installer.
Et voila.