Technical News | Page 1

Deploy ARender with Docker!

Written by Maxime | Oct 13, 2016 4:00:00 AM

ARender can be easily deployed with Docker, follow this tutorial to know how!

At the moment, ARender HMI is in a migration phase towards docker-compose, the rendition server is still using the Dockerfile.

Requirements:

Let’s start with the rendition server, as we need to get its IP at the moment to edit the HMI war:

  • Dockerfile
    • The Dockerfile possesses a build-arg allowing to choose the correct version of the rendition server.

      • ––build-arg VERSION=<version_number>
    • As an example, using version 3.1.0-3:

      • docker build -t rendition-3.1.0-3 –build-arg VERSION=3.1.0-3 ./
      • docker run -p 1789:1789 -p 1990:1990 -d rendition-3.1.0-3
      • add a « –restart=always » to docker run if you wish the container to restart automatically

For the HMI server:

  • Create a docker-compose.yml file with the following content: version: ‘2’ services: ARenderHMI image: tomcat ports: « 9090:8080 » volumes: – ./ARenderHMI.war:/usr/local/tomcat/webapps/ARenderHMI.war

  • Fetch the ARender HMI standalone war file and deposit it in the same folder as the docker-compose.yml file, rename the war in ARenderHMI.war (or if you wish to use another name, modify it in the docker-compose.yml file)

  • In the war file, modify in WEB-INF/classes/ the file named arender.xml in order to add the correct rendition servers IPs that you just launched using docker

  • http://localhost:1990/ this value must be replace depending on your settup

  • docker-compose up will then be enough to deploy for you an ARenderHMI exposed at port 9090