WInDocks is a port of Docker’s open source to Windows. WinDocks supports all editions of Windows 8, Windows 10, Windows Server 2012, and Windows Server 2016, and now includes a new Windows container (similar to the scratch container for Linux). The new Windows container is designed to support “container ready” executables, and works great with Tomcat, Jetty, Nginx, and Node.js.
In this article we’ll look at containers for Java and Tomcat, based on the free WinDocks Community Edition.
The WinDocks setup is an automated 15 minute install on any edition of Windows OS family. WinDocks uses standard Docker commands which can be run locally or from a remote client. In this article we’ll use a local client on a Windows 8 home edition laptop as our container server!
Windows containers behave like Linux containers, with speed, portability of containers and images, and great economy. A survey of WinDocks customers shows an average reduction in VMs used of 5x, and for dev and test usage the reduction in VMs averages close to 10x.
How does WinDocks compare to Microsoft’s container support on Windows Server 2016?
1) Microsoft’s supports Windows Server 2016 and Windows 10 Enterprise editions only, while WinDocks supports all editions of Windows 8 and Windows Server 2012 onward. 2) Microsoft has two SQL Server Express dockerfiles on Dockerhub, but provides no build time support for attaching SQL Server databases! WinDocks supports all editions of SQL Server 2008 onward, with dockerfile support for adding or mounting databases and running SQL Server scripts. SQL Server containers built using WinDocks are complete and ready for use.
We don’t argue when some observe that Microsoft’s design serves to maximizes SQL Server instances and license revenues.
WinDocks ships with a \Samples folder that includes dockerfiles for Ngnix, Node.js, Tomcat, Jetty, and of course .NET and SQL Server. The Tomcat test folder is shown below, along with a sample Dockerfile. The Dockerfile uses the new “Windows” image, along with Tomcat version 7.0.72, and a PowerShell script that sets the Tomcat server port to the container port.
If you have a WAR file, it could be added with an additional COPY command, or it could be pulled from the appropriate repo. The command to build the container is >docker build
Opening a browser to localhost:
Now that we’ve created a running container, we can commit this as an image, with >docker commit
Each Tomcat container is built with a dockerfile that includes a script to ensure the Tomcat port is matched to the container port. Again, the container has a ContainerID, and port, and we can start it as shown.
And, the result is easily confirmed with a refreshed browser pointing to the new container port.
If you haven’t explored the use of containers, now is the time! WinDocks customers use a single VM to support a team of developers or testers, saving time and money. One WinDocks customer uses a bare metal host with 8 cores and 96 GB of RAM, to support twenty SQL Server containers for dev and test. Each container includes over twenty large databases! Prior to using containers, each VM took over an hour to provision. Using WinDocks the time is down to a couple of minutes. The result is a 20x reduction in VMs, a 5:1 reduction in CPU cores, and a dramatic financial savings in MS license costs.
Join thousands worldwide who have downloaded the WinDocks Community Edition, and explore the new world of containers with your own copy at Download WinDocks Community Edition.