I was able to successfully create an AMI (Amazon Mirror Image) of the Laravel server that I just created. I launched it and it worked perfectly. Creating an image from a running instance is quite easy. Just go the EC2 Dashboard. Select Instances and choose the Instance you want to clone. Go to Actions and select Create Image. It takes several minutes to create an image. Once the AMI is created, you can launch another instance using the AMI that you just created. It took close to 3-5 minutes before the server was able to serve Laravel page that was recently installed. In the future, if I want to launch a clean Laravel install, I can just launch an instance based on the AMI I just created.
An alternative way to install a LAMP server in Ubuntu is to use the Tasksel utility. Make sure Tasksel is installed by installing it first via apt-get. Once tasksel is installed, you can then install the lamp-server.
# install tasksel sudo apt-get -y install tasksel # install lamp server sudo tasksel install lamp-server
Years ago, I got tired of Windows for numerous reasons which I don’t have the time to elaborate in this post. Eventually, I switched to Linux. It was new, exciting, and the opportunity to learn something entirely different was fascinating to me. When Ubuntu Dapper Drake came along, I went all in. That was my desktop of choice for a very long time.
After each Ubuntu release, I worked hard to get everything working from the flash player, media, and just about every tool that I needed, just to get the desktop to function the way I wanted to. After several years of Ubuntu updates and fixing the desktop, I got tired of it. It was an exercise I really didn’t want to do every six months.
I switched to the Mac OS because it it’s based on BSD, a Unix variant, which is familiar to me. In some ways, I can get still get down and dirty using the Terminal if I wanted to. The Mac OS for the most part, is a very stable environment. And everything worked at get-go. I’ve been a Mac OS user ever since.
When adding an existing user to a group, be careful of using ‘usermod.’ If done incorrectly, you can remove a user from its existing groups. In my case, I used ‘usermod’ to add myself to the www-data group. Since I did it wrong, I lost ‘sudo’ access on the next reboot. I ended up booting up from a rescue CD and restoring /etc/groups. Thankfully, Ubuntu keeps a backup copy called /etc/groups-.
sudo usermod -G www-data username
sudo usermod -a -G www-data username