summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--common/src/test/resources/demo/Notes.txt31
-rw-r--r--packages/policy-clamp-docker/src/main/docker/controlloop-runtime.sh5
-rw-r--r--packages/policy-clamp-docker/src/main/docker/http-participant.sh7
-rw-r--r--packages/policy-clamp-docker/src/main/docker/kubernetes-participant.sh7
-rw-r--r--packages/policy-clamp-docker/src/main/docker/policy-participant.sh5
-rw-r--r--packages/policy-clamp-tarball/src/main/resources/etc/ClRuntimeParameters.yaml2
-rw-r--r--packages/policy-clamp-tarball/src/main/resources/etc/HttpParticipantParameters.yaml3
-rw-r--r--packages/policy-clamp-tarball/src/main/resources/etc/KubernetesParticipantParameters.yaml4
-rw-r--r--packages/policy-clamp-tarball/src/main/resources/etc/PolicyParticipantParameters.yaml2
9 files changed, 48 insertions, 18 deletions
diff --git a/common/src/test/resources/demo/Notes.txt b/common/src/test/resources/demo/Notes.txt
index 43b75e915..f937e0969 100644
--- a/common/src/test/resources/demo/Notes.txt
+++ b/common/src/test/resources/demo/Notes.txt
@@ -14,15 +14,14 @@ Go to clamp/runtime-controlloop
mvn spring-boot:run -Dspring-boot.run.arguments="--topicServer=localhost --mariadb.host=localhost"
Run Participant from command line using Maven
-mvn spring-boot:run -Dspring-boot.run.arguments="--server.port=8080 --topicServer=localhost"
-mvn spring-boot:run -Dspring-boot.run.arguments="--server.port=8081 --topicServer=localhost"
-mvn spring-boot:run -Dspring-boot.run.arguments="--server.port=8082 --topicServer=localhost"
+mvn spring-boot:run -Dspring-boot.run.arguments="--server.port=8080
+mvn spring-boot:run -Dspring-boot.run.arguments="--server.port=8081
+mvn spring-boot:run -Dspring-boot.run.arguments="--server.port=8082
Run Participant from command line using Jar
-java -jar -Dserver.port=8080 -DtopicServer=localhost target/policy-clamp-participant-impl-simulator-6.1.2-SNAPSHOT.jar
-java -jar -Dserver.port=8081 -DtopicServer=localhost target/policy-clamp-participant-impl-dcae-6.1.2-SNAPSHOT.jar
-java -jar -Dserver.port=8082 -DtopicServer=localhost target/policy-clamp-participant-impl-policy-6.1.2-SNAPSHOT.jar
-java -jar -DtopicServer=localhost target/policy-clamp-participant-impl-kubernetes-6.1.2-SNAPSHOT.jar
+java -jar -Dserver.port=8080 target/policy-clamp-participant-impl-simulator-6.1.2-SNAPSHOT.jar
+java -jar -Dserver.port=8082 target/policy-clamp-participant-impl-policy-6.1.2-SNAPSHOT.jar
+java -jar target/policy-clamp-participant-impl-kubernetes-6.1.2-SNAPSHOT.jar
Config of DB
@@ -39,6 +38,24 @@ MariaDB [(none)]> SHOW GRANTS for 'policy'@localhost;
+---------------------------------------------------------------------------------------------------------------+
2 rows in set (0.000 sec)
+//Generate the keystore
+//clone policy/docker
+cd docker/csit
+./gen_truststore.sh
+./gen_keystore.sh
+//the keystore generated: /docker/csit/config/ks.jks
+
+Run Participant from command line using Docker
+docker run --add-host=message-router:<ip-router> -p 6969:6969 --mount type=bind,source=<path-keystore-file>,target=/opt/app/policy/clamp/etc/ssl/policy-keystore onap/policy-clamp-cl-runtime
+docker run --add-host=message-router:<ip-router> -p 8083:8083 --mount type=bind,source=<path-keystore-file>,target=/opt/app/policy/clamp/etc/ssl/policy-keystore onap/policy-clamp-cl-k8s-ppnt
+docker run --add-host=message-router:<ip-router> --mount type=bind,source=<path-keystore-file>,target=/opt/app/policy/clamp/etc/ssl/policy-keystore onap/policy-clamp-cl-http-ppnt
+docker run --add-host=message-router:<ip-router> --mount type=bind,source=<path-keystore-file>,target=/opt/app/policy/clamp/etc/ssl/policy-keystore onap/policy-clamp-cl-pf-ppnt
+
+Note:
+/policy-clamp-tarball/src/main/resources/etc/ssl/policy-truststore is the truststore for DMaap of oom project
+Participant-k8 swagger: https://localhost:8083/onap/k8sparticipant/swagger-ui/
+CL-Runtime swagger: https://localhost:6969/onap/controlloop/swagger-ui/
+
Run Policy API:
mvn exec:java -Dexec.mainClass=org.onap.policy.api.main.startstop.Main -Dexec.args="-c ../../clamp-tpn/tosca-controlloop/common/src/test/resources/demo/policy-api/PolicyAPIConfig.json"
diff --git a/packages/policy-clamp-docker/src/main/docker/controlloop-runtime.sh b/packages/policy-clamp-docker/src/main/docker/controlloop-runtime.sh
index 6d12e590a..59d31dc8e 100644
--- a/packages/policy-clamp-docker/src/main/docker/controlloop-runtime.sh
+++ b/packages/policy-clamp-docker/src/main/docker/controlloop-runtime.sh
@@ -56,8 +56,9 @@ touch /app/app.jar
mkdir -p "${POLICY_HOME}"/config/
cp -f "${CONFIG_FILE}" "${POLICY_HOME}"/config/ClRuntimeParameters.yaml
-$JAVA_HOME/bin/java -Djavax.net.ssl.keyStore="${KEYSTORE}" \
- -Djavax.net.ssl.keyStorePassword="${KEYSTORE_PASSWD}" \
+$JAVA_HOME/bin/java -Dserver.ssl.enabled="true" \
+ -Dserver.ssl.keyStore="${KEYSTORE}" \
+ -Dserver.ssl.keyStorePassword="${KEYSTORE_PASSWD}" \
-Djavax.net.ssl.trustStore="${TRUSTSTORE}" \
-Djavax.net.ssl.trustStorePassword="${TRUSTSTORE_PASSWD}" \
-jar /app/app.jar \
diff --git a/packages/policy-clamp-docker/src/main/docker/http-participant.sh b/packages/policy-clamp-docker/src/main/docker/http-participant.sh
index d74b903e3..17daa18f9 100644
--- a/packages/policy-clamp-docker/src/main/docker/http-participant.sh
+++ b/packages/policy-clamp-docker/src/main/docker/http-participant.sh
@@ -55,9 +55,10 @@ fi
mkdir -p "${POLICY_HOME}"/config/
cp -f "${CONFIG_FILE}" "${POLICY_HOME}"/config/HttpParticipantParameters.yaml
-$JAVA_HOME/bin/java -Dserver.ssl.keyStore="${KEYSTORE}" \
+$JAVA_HOME/bin/java -Dserver.ssl.enabled="true" \
+ -Dserver.ssl.keyStore="${KEYSTORE}" \
-Dserver.ssl.keyStorePassword="${KEYSTORE_PASSWD}" \
- -Dserver.ssl.trustStore="${TRUSTSTORE}" \
- -Dserver.ssl.trustStorePassword="${TRUSTSTORE_PASSWD}" \
+ -Djavax.net.ssl.trustStore="${TRUSTSTORE}" \
+ -Djavax.net.ssl.trustStorePassword="${TRUSTSTORE_PASSWD}" \
-jar /app/app.jar \
--spring.config.location="${POLICY_HOME}/config/HttpParticipantParameters.yaml"
diff --git a/packages/policy-clamp-docker/src/main/docker/kubernetes-participant.sh b/packages/policy-clamp-docker/src/main/docker/kubernetes-participant.sh
index cb5ae9251..3c5fe5c63 100644
--- a/packages/policy-clamp-docker/src/main/docker/kubernetes-participant.sh
+++ b/packages/policy-clamp-docker/src/main/docker/kubernetes-participant.sh
@@ -55,9 +55,10 @@ fi
mkdir -p "${POLICY_HOME}"/config/
cp -f "${CONFIG_FILE}" "${POLICY_HOME}"/config/KubernetesParticipantParameters.yaml
-$JAVA_HOME/bin/java -Dserver.ssl.keyStore="${KEYSTORE}" \
+$JAVA_HOME/bin/java -Dserver.ssl.enabled="true" \
+ -Dserver.ssl.keyStore="${KEYSTORE}" \
-Dserver.ssl.keyStorePassword="${KEYSTORE_PASSWD}" \
- -Dserver.ssl.trustStore="${TRUSTSTORE}" \
- -Dserver.ssl.trustStorePassword="${TRUSTSTORE_PASSWD}" \
+ -Djavax.net.ssl.trustStore="${TRUSTSTORE}" \
+ -Djavax.net.ssl.trustStorePassword="${TRUSTSTORE_PASSWD}" \
-jar /app/app.jar \
--spring.config.location="${POLICY_HOME}/config/KubernetesParticipantParameters.yaml"
diff --git a/packages/policy-clamp-docker/src/main/docker/policy-participant.sh b/packages/policy-clamp-docker/src/main/docker/policy-participant.sh
index 7949fab72..77cd0c02b 100644
--- a/packages/policy-clamp-docker/src/main/docker/policy-participant.sh
+++ b/packages/policy-clamp-docker/src/main/docker/policy-participant.sh
@@ -56,8 +56,9 @@ touch /app/app.jar
mkdir -p "${POLICY_HOME}"/config/
cp -f "${CONFIG_FILE}" "${POLICY_HOME}"/config/PolicyParticipantParameters.yaml
-$JAVA_HOME/bin/java -Djavax.net.ssl.keyStore="${KEYSTORE}" \
- -Djavax.net.ssl.keyStorePassword="${KEYSTORE_PASSWD}" \
+$JAVA_HOME/bin/java -Dserver.ssl.enabled="true" \
+ -Dserver.ssl.keyStore="${KEYSTORE}" \
+ -Dserver.ssl.keyStorePassword="${KEYSTORE_PASSWD}" \
-Djavax.net.ssl.trustStore="${TRUSTSTORE}" \
-Djavax.net.ssl.trustStorePassword="${TRUSTSTORE_PASSWD}" \
-jar /app/app.jar \
diff --git a/packages/policy-clamp-tarball/src/main/resources/etc/ClRuntimeParameters.yaml b/packages/policy-clamp-tarball/src/main/resources/etc/ClRuntimeParameters.yaml
index ade249e99..c8601cbdd 100644
--- a/packages/policy-clamp-tarball/src/main/resources/etc/ClRuntimeParameters.yaml
+++ b/packages/policy-clamp-tarball/src/main/resources/etc/ClRuntimeParameters.yaml
@@ -44,12 +44,14 @@ runtime:
- ${topicServer:message-router}
topicCommInfrastructure: dmaap
fetchTimeout: 15000
+ useHttps: true
topicSinks:
-
topic: POLICY-CLRUNTIME-PARTICIPANT
servers:
- ${topicServer:message-router}
topicCommInfrastructure: dmaap
+ useHttps: true
management:
endpoints:
diff --git a/packages/policy-clamp-tarball/src/main/resources/etc/HttpParticipantParameters.yaml b/packages/policy-clamp-tarball/src/main/resources/etc/HttpParticipantParameters.yaml
index 76f48bbdd..be421fcae 100644
--- a/packages/policy-clamp-tarball/src/main/resources/etc/HttpParticipantParameters.yaml
+++ b/packages/policy-clamp-tarball/src/main/resources/etc/HttpParticipantParameters.yaml
@@ -15,9 +15,10 @@ participant:
- ${topicServer:message-router}
topicCommInfrastructure: dmaap
fetchTimeout: 15000
+ useHttps: true
topicSinks:
- topic: POLICY-CLRUNTIME-PARTICIPANT
servers:
- ${topicServer:message-router}
topicCommInfrastructure: dmaap
-
+ useHttps: true
diff --git a/packages/policy-clamp-tarball/src/main/resources/etc/KubernetesParticipantParameters.yaml b/packages/policy-clamp-tarball/src/main/resources/etc/KubernetesParticipantParameters.yaml
index ebd744f13..d605cfa1d 100644
--- a/packages/policy-clamp-tarball/src/main/resources/etc/KubernetesParticipantParameters.yaml
+++ b/packages/policy-clamp-tarball/src/main/resources/etc/KubernetesParticipantParameters.yaml
@@ -26,12 +26,14 @@ participant:
- ${topicServer:message-router}
topicCommInfrastructure: dmaap
fetchTimeout: 15000
+ useHttps: true
topicSinks:
-
topic: POLICY-CLRUNTIME-PARTICIPANT
servers:
- ${topicServer:message-router}
topicCommInfrastructure: dmaap
+ useHttps: true
management:
endpoints:
@@ -42,6 +44,8 @@ server:
# Configuration of the HTTP/REST server. The parameters are defined and handled by the springboot framework.
# See springboot documentation.
port: 8083
+ servlet:
+ context-path: /onap/k8sparticipant
logging:
# Configuration of logging
diff --git a/packages/policy-clamp-tarball/src/main/resources/etc/PolicyParticipantParameters.yaml b/packages/policy-clamp-tarball/src/main/resources/etc/PolicyParticipantParameters.yaml
index 66e2d95b6..bd9a6260a 100644
--- a/packages/policy-clamp-tarball/src/main/resources/etc/PolicyParticipantParameters.yaml
+++ b/packages/policy-clamp-tarball/src/main/resources/etc/PolicyParticipantParameters.yaml
@@ -35,9 +35,11 @@ participant:
- ${topicServer:message-router}
topicCommInfrastructure: dmaap
fetchTimeout: 15000
+ useHttps: true
topicSinks:
-
topic: POLICY-CLRUNTIME-PARTICIPANT
servers:
- ${topicServer:message-router}
topicCommInfrastructure: dmaap
+ useHttps: true