apache tomcat
Java spp server used for running Java Servlet, JSP, and WebSocket-based applications.
What is apache tomcat
The apache tomcat image packages Apache Tomcat, an open-source Java application server used for running Java Servlet, JSP, and WebSocket-based applications. Tomcat is widely adopted in enterprise environments for deploying lightweight, containerized Java web applications.
This image includes a full Tomcat runtime, a web interface, and tools for deploying .war files to the servlet container. It supports running applications out of the box with minimal configuration and is often used in testing environments, internal services, or legacy application migrations.
The tomcat image is a straightforward way to deploy Java-based applications without managing a full JEE stack like WildFly or WebLogic. It’s useful for developers building or maintaining Java web services that rely on servlets, JSPs, or static content.
How to use this image
The tomcat image runs the Tomcat server and exposes the web interface on port 8080.
Run a default Tomcat server:
Deploy a .war file by mounting it into the webapps directory:
Build a custom Tomcat image with your .war
file preloaded:
Logging and ports:
Tomcat logs are printed tostdout
and stderr
, viewable via docker logs
. The main web interface is accessible at http://localhost:8080
by default.
Image variants
The official Tomcat image offers several variants based on version, JDK flavor, and base OS:
Points to the latest stable Tomcat version (currently Tomcat 10) with the default JDK and Debian base. Use for general-purpose testing or development.
Tagged by Tomcat major/minor version (e.g.tomcat:9.0
, tomcat:10.1
). Use to pin your environment to a specific servlet API version.
Specifies the JDK version bundled (e.g.tomcat:10.1-jdk17
, tomcat:9.0-jdk11
). Use when your app targets a specific Java runtime.
Based on Alpine Linux for a smaller image size (e.g.tomcat:10.1-jdk17-temurin-alpine
). Use when size and reduced dependencies are priorities.
Versioned tags (e.g.tomcat:10.1.19-jdk17
) are recommended for reproducible builds and to avoid unintended upgrades.