Mattifesto Web Server And Web Site Domain Name Strategy

Notes

Most Web Servers Run Multiple Websites

In my situation almost every web server runs multiple sites. This is especially true for development and test sites that don't have much data. As websites get larger, that reverses to where each website might have multiple web servers and the database moves to its own server.

In most Mattifesto Devs documents, we focus on relatively small websites that single developers or small teams can build and maintain, because that's the perspective that most developers face.

Reserved IP Addresses

When setting up a private development or test web server you will create a virtual machine on VirtualBox. That machine will have the following network attributes:

  • a unique MAC address

  • a local IP address reserved for that MAC address

  • a public DNS A record associated with that local IP address

You will reserve IP addresses using your router. Not all routers are good at this. My cable router has bugs in this area, so I have an Apple AirPort Extreme set up in my office and all development machines are networked through that. There are many routers that are good at this, the Airport Extreme is just one of them.

We really push for this exact situation because we don't want to use a different set of skills, policies, and procedures for private servers. These skills are easy to build and will benefit you for the rest of your life.

Web Server Domain Names

Unique Machine Index

Each web server has a unique machine index that is used only once for one server of any kind: development, test, production, local, or internet. Once that server is retired, that index is also retired. The index is incremented each time a new server is created. This index will quickly move into the hundreds or even thousands.

When a new version of Ubuntu is released we create entirely new web servers. Old servers will be retired and their domain names will never be used again.

We use these unique indexes because processes get a lot easier and faster if you are starting from scratch each time and don't have to worry about whether you properly reset previous server concepts and entities back "to zero".

My web servers are given domain names in the following fashion. We are using a machine index of 42 in the examples.

Local Network Development Web Server

ld42.mtfs.us

Local Network Test Web Server

lt42.mtfs.us

Local Network Production Web Server

lp42.mtfs.us

Internet Staging Web Server

is42.mtfs.us

Internet Production Web Server

ip42.mtfs.us

Development and Test Website Domain Names

The following examples a domain names that might be used for development and test websites for the yaycomputer.com internet website.

happyfunmatt.ld42.mtfs.us
happyfunmatt.lt43.mtfs.us
happyfunmatt.is44.mtfs.us

Website domains should have DNS CNAME record that point to their server domain.

happyfunmatt.ld42.mtfs.us => ld42.mtfs.us

Production Website Domain Names

For production websites the domain name should be whatever you want. They should also have DNS A or CNAME records that point to their web server.

happyfunmatt.com => 222.222.222.222

humanresources.mattifesto.com => lp52.mtfs.us

History

Before Colby was open source I would host all my websites on DreamHost. After it was open source I knew I had to have a non-vendor reliant method of hosting websites that everyone could use and modify to their own preferred services.

I was also developing websites using the Apache web server running on the Mac. This worked for me for many years but a number of factors make that also not a great idea anymore.

The current methods have all environments running on the same web server software. That's a good thing that allows us to simplify that process as much as possible and provide you with a chance to gain mastery over a skill that will serve you throughout your current and future endeavors.

This document is a living document representing my current strategies and recommendations.