0

I have war file which consist of javascript,html code and a Dockerfile.How should I convert it into the Docker image ? Do I need to make any changes in the Dockerfile ? Or should I just write the following command and it will work ?

Command: COPY //techpoint.war /usr/local/tomcat/webapps/techpoint.war

user34
  • 103
  • 1
  • 1
  • 7

1 Answers1

1

Yes, you need to add the copy command in your DockerFile. after that use :

sudo docker build folder-containing-dockerFile
  • But where will be the image file stored. – user34 Feb 20 '19 at 10:49
  • Actually the Dockerfile contains following lines: ARG INSTALL_URL=https://github.com/xxx/yyy/releases/download/${XYZ_VERSION}/xyz-web-${XYZ_VERSION}.war and COPY /build/scripts/start-web.sh /usr/local/bin/ COPY /build/mail.zip /assets/mail.zip RUN chmod a+x /usr/local/bin/start-web.sh \ && curl -SL ${INSTALL_URL} -o xyz-web.war \ (this INSTALL_URL command is not required to me instead of that I need to add my .war file make changes in the RUN command and build Image) – user34 Feb 20 '19 at 10:55
  • the storage directory vary depending on the driver Docker is using for storage. refer to https://stackoverflow.com/questions/19234831/where-are-docker-images-stored-on-the-host-machine –  Feb 20 '19 at 12:52