How Do You Deploy Apache Tomcat in a Docker Instance in an AWS Ubuntu Linux Server?

Problem scenario
You want to deploy Apache Tomcat in a Docker container on an AWS instance of Ubuntu Linux.  How do you do this?

Solution
1.  Install Docker.  See this link if you need assistance.
2.  Start the Docker service with this command:  sudo service docker start
3.  Run these two commands:

docker pull consol/tomcat-8.0
docker run consol/tomcat-8.0

4. 

How Do You Configure Nginx in a Docker Container to Be an HTTP Load Balancer?

Updated on 11/7/17

Problem scenario
You want a computer server (e.g., an AWS instance) to be a reverse proxy (a type of landing page users do not see that acts as a portal).  You want it to relay traffic to other IP addresses.  How do you get a server with Docker to distribute traffic to other IP endpoints?

Solution
Prerequisites
This assumes that Docker has already been installed. 

How Do You Optimize a Website’s Performance That Is Running Nginx as a Load Balancer in a Docker Container?

Problem scenario
You want web page refreshes to happen more quickly for your website when a user clicks “Reload” in her web browser.  The website you manage is powered by Nginx configured as an HTTP load balancer (aka a reverse proxy).  This Nginx configuration is in a Docker container too. The rule you want is that clients’ inbound connection requests from a specific IP address should be relayed to the same Nginx server every time that client reloads the web page in the web browser.

How Do You Use the ip_hash Directive in Nginx Running in Docker and Be Able to Stop and Start the Docker Container Again?

Problem scenario
You are using Nginx as a reverse proxy (a server that is essentially a landing page that is invisible to users and passes connection requests to other web servers like a router).  You noticed that when you added the “ip_hash;” directive in the “upstream server {}” section (also known as a block) of the /etc/nginx/conf.d/default.conf file, you lose the Docker container.  That is if you stop the Docker container once the Nginx default.conf file has this “ip_hash;” directive,

How Do You Set up Nginx as an HTTP Load Balancer So Client Requests (from Web Browsers) Do Not Go to Nginx Servers That Have Failed Several Times in Recent Attempts?

Problem scenario
To improve performance of your HTTP load balancing mechanism, you want to configure how failed members of the load balancer are dealt with. Some Nginx instances may fail in your environment. You do not want attempts to send web traffic to these instances immediately after several failures.  How do you granularly keep track of failed attempts and remove the instance from the distribution algorithm after a certain limit has been reach to improve performance by attempting only more reliable instances?

How Do You Deploy Several Docker Containers with Nginx and Have Each of Them Work Simultaneously on a Single RedHat Server?

Problem scenario
You want to create several Docker containers each supporting Nginx.  You want to be able to browse to the different instances of Nginx from a web browser.  How do you have multiple Docker containers support Nginx on one RedHat Enterprise Linux host server?

Solution
These directions are geared toward a RHEL host server instance in AWS.

#1 Install Docker.

How Do You Have Text Fields That Have Hints (Suggested Text)?

Problem scenario
You are using PHP files (with HTML).  You have text fields that are blank by default.  These fields accept user input from the keyboard.  You want the clear text fields to have suggested text by default (to help explain to the user the type of input that is appropriate or to remind the user of content restrictions).  How do you do this?

You have a field that requests text like this HTML code (in a .php file):

<html>

How Do You Install Octopus Deploy server to a Windows 2016 Server?

Problem scenario
You want to install Octuopus Deploy (e.g., with the 45 free trial) to an AWS instance of Windows Server 2016.  How do you do this?

Solution
This is a simple deployment of Octopus Deploy server for testing or evaluation purposes.  Literally any AWS flavor will work as only 512 MB of RAM is needed for Octopus Deploy server to work for minimal evaluation.

How Do You Deploy JetBrains TeamCity to an AWS Windows Server 2016?

Problem scenario
You want to deploy TeamCity to an AWS instance running Windows Server 2016.  How do you do this?

Solution
This is a simple deployment of TeamCity server for testing or evaluation purposes. The flavor of server will depend on the way you use TeamCity server.  For a basic deployment, one processor and 1 GB of RAM is sufficient.  This is far from enough CPU and memory for any “real” usage of TeamCity.