Uploaded image for project: 'PUBLIC - Liferay Portal Community Edition'
  1. PUBLIC - Liferay Portal Community Edition
  2. LPS-70290

Support switching to a Dockerized liferay instance instead of using the testable tomcat on build

    Details

      Description

      As we (Cristina Gonzalez and Andrea Di Giorgi) were talking, we'd like to be able to hook the testable tomcat lifecycle, to not use the bundle present on source code, using a docker image configured in the same way instead.

      For that, the build must perform some checks to determine if it must use the bundle or the docker image.

      As an example, but not necessarily done this way, and following the same approach that the WeDeploy team uses, if the project (mainly subrepos) has a container.json file describing the image the project needs, then the docker image will be used instead of the bundle.

      That descriptor must hold information about:

      • Liferay docker image (i.e. mdelapenya/liferay-portal:7-ce-ga3-tomcat-hsql)
      • volumes
        • "host-path:container-path"
      • ports
        • "host-port:container-port"
      • env variables
        • JAVA_OPTS="jmxOptions debugMode"

      So that the build system will run a docker container from the image, with some JAVA_OPTS added to the environment variables, exposing some ports, and declaring some volumes.

      An initial approach would be executing a docker command as the following example:

      docker run -p $PORT_1 -p $PORT_n -v $VOL_1 -v $VOL_n -e ENV_1 -e $ENV_n -d $LIFERAY_IMAGE
      

      But in the near future, or if we consider it, we could move to another approach based on using an already existing Docker Gradle plugin.

        Attachments

          Activity

            People

            • Assignee:
              peter.shin Peter Shin
              Reporter:
              manuel.delapenya Manuel de la Peña (Inactive)
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:

                Packages

                Version Package
                7.0.0 DXP SP3
                7.0.3 CE GA4