Centos

Centos PHP 7 LAMP boilerplate

Centos PHP 7 LAMP boilerplate

This time we are going to cook Apache (httpd 2.4), PHP 7.0 as a PHP-FPM . Instructions are pretty simple. You can just copy and paste command to get working stack in less then 15 minutes.

What you can learn from it? How to install Apache 2.4 and PHP 7, how to enable and opcache, and how to install HTTPS on your server, with purchasing SSL certificate.

PHP 5.4.x on CentOS 6.5

PHP 5.4.x on CentOS 6.5

Quick copy and paste list of commands to get PHP 5.4 on CentOS boxes

wget http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
wget http://rpms.famillecollet.com/enterprise/remi-release-6.rpm
sudo rpm -Uvh remi-release-6*.rpm epel-release-6*.rpm

Enable remi repo

sudo nano /etc/yum.repos.d/remi.repo

Update

sudo yum update
sudo yum info php
Loaded plugins: fastestmirror, refresh-packagekit, security
Loading mirror speeds from cached hostfile
 * base: mirror.optus.net
 * epel: fedora.mirror.serversaustralia.com.au
 * extras: ftp.swin.edu.au
 * remi: remi.kazukioishi.net
 * updates: ftp.swin.edu.au
Available Packages
Name        : php
Arch        : x86_64
Version     : 5.4.33
Release     : 2.el6.remi
Size        : 2.7 M
Repo        : remi

done…

CentoOS 7 NFS support

CentoOS 7 NFS support

CentOS is pretty new, and some default stuff is just missing. Like NFS suport out of the box.

We have to install package called nfs-utils

yum -y install nfs-utils

we can mount using standard mount 192.168.1.15:/c/share

mount -a 

to make it parmament

edit /etc/fstab

192.168.1.15:/c/share /mnt/nfs nfs defaults 0 0

Shuttle XS35 V2 and CentOs drivers

Some time ago I bought extremely quiet Shuttle XS35 V2  device to have something “seperate” for my web development work. Right now this awesome fan less device has many purposes. Works as full web dev stack, with Apache, PHP, MySQL, mongoDB, and even Jenkins machine.

Recently I realised that this small ugly device got also WiFi cart into it. Because I’m running out of cables and space in my apartment i figure out, that I could move it easily without plugging into it more cables.

How to Install GeoIP extension on CentOS

How to Install GeoIP extension on CentOS

Small 2019 update – Please check out this library – github.com/maxmind/MaxMind-DB-Reader-php . It’s a straight replacement of PHP module.

GeoIP from PECL is powerful extension used to determine geographical locations of IP addresses and domain names. This is useful if you want to set a language or redirection based on location of your visitor. Check out the PHP docs for a full list of GeoIP functions .