Laravel routes not working

If your main Laravel page is working but no other routes are then this may be of use to you.

My doc root is here:


Firstly enable mod rewrite:

sudo a2enmod rewrite

Then check your routes that weren’t loading, if it works great! If not, then read on.

Edit your default apache site conf file:

sudo gedit /etc/apache2/sites-enabled/000-default.conf

Mine is below:

<VirtualHost *:80>
    ServerName localhost
    ServerAdmin webmaster@localhost
    DocumentRoot /var/www/html/quickstart/public
    ErrorLog ${APACHE_LOG_DIR}/error.log
    CustomLog ${APACHE_LOG_DIR}/access.log combined
    <Directory "/var/www/html/quickstart/public">
        Allowoverride All
# vim: syntax=apache ts=4 sw=4 sts=4 sr noet

That worked for me on Ubuntu, hope it helps someone.

I have been trying out laravel and intend to use it for some projects in the future but I’ve been finding it very frustrating to get it installed and running. The homstead vagrant setup they have just simply doesn’t work and this is the second time I’ve tried it over the past 3 months, so it wasn’t a passing bug. I’ve only ever got laravel up and running on Linux by setting it up manually and never got it working on windows. Hopefully after a few fresh installs I’ll have it down to a few nice steps and I’ll write those up =)

Watchdog Script

I was looking  for a script to monitor a process and restart it if it failed on Linux, so here is a watch dog script that I found on SO, here:

The script will watch a process and restart it if it is not running.

The script



while :
    RESULT=`pgrep ${PROCESS}`
    if [ "${RESULT:-null}" = null ]; then
        echo "${PROCESS} not running, starting "$PROCANDARGS
        $PROCANDARGS &
         echo "running"
    sleep 10



Let’s say the script is named “”

make sure it is executable:

chmod +x ./

As an example we’ll keep gedit running, run it as below:

./wdt/sh gedit

Installing Jira on AWS

Jira is a widely used issue tracker, among other things. Below is a set of steps to get it up and running on an AWS server (Amazon’s Web Services).

NB: Do not try to install Jira on the free tier AWS servers, they are simply not powerful enough and run out of memory during installation. I found out the slow and tedious way!

Continue reading Installing Jira on AWS

Setup git Repo

Some useful reference steps for setting up your git repo. Works on both Linux and Windows command line, just note that the “touch” won’t work on windows, just create a new txt file instead.

Setup your name and email

git config --global "name"
git config --global ""

Create a new repository

mkdir my-project
cd my-project
git init
git add
git commit -m "first commit"
git remote add origin
git push -u origin master

Push an existing Git repository

cd existing_git_repo
git remote add origin
git push -u origin master

Installing mariadb for CentOS

Reference commands for install and setup of mysql / mariadb on red hat distros like CentOS.

The below commands install the server, enable the database service to start on boot, setup the database service and finally start the service.

yum install mariadb-server mariadb

systemctl enable mariadb.service


systemctl start mariadb.service

Install SVN from source

I’ve been having problems recently with SVN not being kept up to date on a company repo. So I installed SVN from source so that I could use a modern GUI.

(smartsvn has a free version which I opted to use but once it had upgraded my repos they no longer worked with the command line client – so that needed updating)

Installing from source

yum update
yum groupinstall "Development tools"
yum groupinstall "Additional Development"
tar zxvf subversion-1.8.9.tar.gz
cd subversion-1.8.9
make check
sudo make install

If APR and APRUTIL cannot be found

If you find that it complains about APR and APRUTIL missing during the configure command then run this line instead:

./configure --with-apr=/usr/local/apr/ --with-apr-util=/usr/local/apr/

Test internet connectivity from bash script

Ensure you have curl installed and then you can use the following bash code in your scripts to test for internet connectivity.



echo "Testing connection..."

curlOutput=$(curl -I

# Possible cases, there are more but here we cover:
# 407 which can mean bad proxy details,
# 200 which means everything is OK,
# 302 which is a redirection but for us that's OK too.

if [[ $curlOutput == *"407"* ]]
 echo "No internet connection, bad proxy username / password";

if [[ $curlOutput == *"200"* ]]
 echo "internet connection OK";

if [[ $curlOutput == *"302"* ]]
 echo "internet connection OK";


Enjoy 🙂