Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

193
Vistas
Running a Java war file deployed on Tomcat over Windows server 2016 Docker container

Trying to run a Java .war file with Docker on Windows server 2016.

With Linux container it can be done by pulling Tomcat image (which is built on top of openJDK and uses Debian as a base image) and adding war file to webapps folder through Dockerfile.

But, Tomcat do not currently has any image for Windows containers, since openJDK too doesn't have support for Microsoft/windowsservercore or Microsoft/nanoserver

In my view, to be able to run war on Tomcat for windows We will need:

  • windowsservercore
  • JDK:JRE installation on top of windowsservercore
  • Tomcat installation with Environment Vars of installed JDK.

To create the final image JDK is downloaded and installed through PS :

The Dockerfile looks like:

FROM windowsservercore

RUN powershell (new-object System.Net.WebClient).Downloadfile('http://javadl.oracle.com/webapps/download/Au toDL?BundleId=210185', 'C:\jre-8u91-windows-x64.exe')
RUN powershell start-process -filepath C:\jre-8u91-windows-x64.exe -passthru  -wait -argumentlist "/s,INSTALLDIR=c:\Java\jre1.8.0_91,/L,install64.log"
RUN del C:\jre-8u91-windows-x64.exe

CMD [ "c:\\Java\\jre1.8.0_91\\bin\\java.exe", "-version"]

But I am not sure how to install Tomcat with Environment variables set and then adding war to the webapps Directory.

Heard about WinDocks, but I would like to build without it.

Anyone has some insights on this?

about 4 years ago · Santiago Trujillo
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda