Installing WordPress 4.9.1 on Debian 9


Install apache2

apt-get install apache2

Install php and add-on's needed for WordPRess 4.9.1

apt-get install php php-mysql php-zip

php-zip php-xml php-mbstring php-gd php-curl

Install MySQL server

See this link for install instructions.

Change wpuser and wppass to a username and password that you want for your owncloud database

mysql -e "CREATE DATABASE wordpress;"
mysql -e "GRANT ALL PRIVILEGES ON wpncloud.* TO 'wpuser'@'localhost' IDENTIFIED BY 'ocpass';"

Get WordPress Files

unzip -d /var/www

Securing WordPress

Set proper permissions for 'data' folder

chown -R www-data:www-data /var/www/wordpress/