aboutsummaryrefslogtreecommitdiffstats
path: root/workflow-designer-ui
diff options
context:
space:
mode:
authoravigaffa <avi.gaffa@amdocs.com>2019-05-05 16:20:24 +0300
committeravigaffa <avi.gaffa@amdocs.com>2019-05-05 16:20:24 +0300
commitaa3351b0197d96469dd1c34abd0489c09756eaa4 (patch)
tree308e96b8a00ae054b1aa63b736395fe59e52853c /workflow-designer-ui
parent1dc6361b5b1d10b30fdd6f93454e67861ed1db35 (diff)
Connection to WF designer times out
Adding support for SSL to WFD-FE Issue-ID: SDC-2246 Change-Id: Ia16327f90e6c96e0584f2e2dbb9b2ee3afd7af08 Signed-off-by: avigaffa <avi.gaffa@amdocs.com>
Diffstat (limited to 'workflow-designer-ui')
-rw-r--r--workflow-designer-ui/docker/Dockerfile16
-rw-r--r--workflow-designer-ui/docker/startup.sh25
-rw-r--r--workflow-designer-ui/pom.xml35
3 files changed, 67 insertions, 9 deletions
diff --git a/workflow-designer-ui/docker/Dockerfile b/workflow-designer-ui/docker/Dockerfile
new file mode 100644
index 00000000..83e8d5ac
--- /dev/null
+++ b/workflow-designer-ui/docker/Dockerfile
@@ -0,0 +1,16 @@
+FROM jetty:9.4.9-alpine
+
+EXPOSE 8080
+EXPOSE 8443
+
+USER root
+
+ARG ARTIFACT
+
+ADD ${ARTIFACT} ${JETTY_BASE}/webapps/
+RUN chown -R jetty:jetty ${JETTY_BASE}/webapps
+
+COPY startup.sh .
+RUN chmod 744 startup.sh
+
+ENTRYPOINT [ "./startup.sh" ] \ No newline at end of file
diff --git a/workflow-designer-ui/docker/startup.sh b/workflow-designer-ui/docker/startup.sh
new file mode 100644
index 00000000..359e6aca
--- /dev/null
+++ b/workflow-designer-ui/docker/startup.sh
@@ -0,0 +1,25 @@
+#!/bin/sh
+
+# adding support for https
+HTTPS_ENABLED=${IS_HTTPS:-"false"}
+
+if [ "$HTTPS_ENABLED" = "true" ]
+then
+ echo "enable ssl"
+ if [ -z "$KEYSTORE_PATH" ]; then
+ java -jar "${JETTY_HOME}/start.jar" --add-to-start=https,ssl \
+ jetty.sslContext.keyStorePath=$KEYSTORE_PATH \
+ jetty.sslContext.keyStorePassword=$KEYSTORE_PASSWORD \
+ jetty.sslContext.keyStoreType=$KEYSTORE_TYPE \
+ jetty.sslContext.trustStorePath=$TRUSTSTORE_PATH \
+ jetty.sslContext.trustStorePassword=$TRUSTSTORE_PASSWORD \
+ jetty.sslContext.trustStoreType=$TRUSTSTORE_TYPE \
+ else
+ echo "Using jetty default SSL"
+ java -jar "${JETTY_HOME}/start.jar" --add-to-start=https,ssl
+ fi
+else
+ echo "no ssl required"
+fi
+
+java -DproxyTo=$BACKEND $JAVA_OPTIONS -jar $JETTY_HOME/start.jar \ No newline at end of file
diff --git a/workflow-designer-ui/pom.xml b/workflow-designer-ui/pom.xml
index 46c24536..4e55001e 100644
--- a/workflow-designer-ui/pom.xml
+++ b/workflow-designer-ui/pom.xml
@@ -147,6 +147,28 @@
<build>
<plugins>
<plugin>
+ <artifactId>maven-resources-plugin</artifactId>
+ <version>2.6</version>
+ <executions>
+ <execution>
+ <id>copy-resources-docker</id>
+ <phase>install</phase>
+ <goals>
+ <goal>copy-resources</goal>
+ </goals>
+ <configuration>
+ <outputDirectory>${basedir}/docker</outputDirectory>
+ <resources>
+ <resource>
+ <directory>${project.build.directory}</directory>
+ <include>${project.artifactId}-${project.version}.war</include>
+ </resource>
+ </resources>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ <plugin>
<groupId>io.fabric8</groupId>
<artifactId>docker-maven-plugin</artifactId>
<configuration>
@@ -157,15 +179,10 @@
<tags>
<tag>${project.version}</tag>
</tags>
- <from>jetty:9.4.11-alpine</from>
- <user>root</user>
- <assembly>
- <descriptorRef>artifact</descriptorRef>
- <targetDir>/var/lib/jetty/webapps</targetDir>
- </assembly>
- <entryPoint>
- java -DproxyTo=$BACKEND $JAVA_OPTIONS -jar $JETTY_HOME/start.jar
- </entryPoint>
+ <dockerFileDir>${project.basedir}/docker</dockerFileDir>
+ <args>
+ <ARTIFACT>${project.artifactId}-${project.version}.war</ARTIFACT>
+ </args>
</build>
</image>
</images>