Installing LAMP on Fedora 22

Quick short rundown reference for LAMP set-up on Fedora

Apache is installed by default, so no need to install Apache, if you where going you would run

$ sudo dnf install httpd

You can run the following by signing into the terminal as root;

$ su –

$ dnf install php

This will install 5.6 by default;

Restart Apache service;

systemctl restart httpd.service

Write up a small test PHP file, I prefer nano for something small like this but you can use vi or even gedit if you prefer;

$ nano /var/www/html/info.php

Insert following PHP code, and then save the file

< ?php phpinfo(); ?>

You should see the php information page display;

Then install MySQL this will install Mariadb by default

$dnf install mysql mysql-server