From 380b7afc7c81a13c3025de0efed050ddbd1d929b Mon Sep 17 00:00:00 2001 From: "Muthuramalingam, Brinda Santh(bs2796)" Date: Thu, 23 Aug 2018 15:54:30 +0000 Subject: Controller Blueprints Microservice Add Docker Build and Deploy Maven Implementations for Controller Blueprint MS and their dependencies Change-Id: I9eee9fff535bcc9ca0b855150892ce53af126d1c Issue-ID: CCSDK-483 Signed-off-by: Muthuramalingam, Brinda Santh(bs2796) --- ms/controllerblueprints/distribution/pom.xml | 187 +++++++++++++++++++++++++++ 1 file changed, 187 insertions(+) create mode 100644 ms/controllerblueprints/distribution/pom.xml (limited to 'ms/controllerblueprints/distribution/pom.xml') diff --git a/ms/controllerblueprints/distribution/pom.xml b/ms/controllerblueprints/distribution/pom.xml new file mode 100644 index 000000000..37c0b8448 --- /dev/null +++ b/ms/controllerblueprints/distribution/pom.xml @@ -0,0 +1,187 @@ + + + + + 4.0.0 + + org.onap.ccsdk.apps.controllerblueprints + parent + 0.3.0-SNAPSHOT + ../parent + + distribution + pom + Controller Blueprints Distribution + + maven + org.onap.ccsdk.apps + controllerblueprints + onap/ccsdk-controllerblueprints + + + + + org.onap.ccsdk.apps.controllerblueprints + application + + + + + + maven-resources-plugin + 2.6 + + + copy-dockerfile + + copy-resources + + validate + + ${basedir}/target/docker-stage + + + src/main/docker + + * + + true + + + + + + + + org.apache.maven.plugins + maven-antrun-plugin + + + ant-test + package + + + + + + + run + + + + + + + maven-assembly-plugin + 3.0.0 + + + ${basedir}/target/docker-stage + + src/main/docker/distribution.xml + + posix + + + + ${assembly.id} + package + + single + + + + + + org.codehaus.groovy.maven + gmaven-plugin + 1.0 + + + validate + + execute + + + + println project.properties['ccsdk.project.version']; + def versionArray; + if (project.properties['ccsdk.project.version'] != null ) { + versionArray = project.properties['ccsdk.project.version'].split('\\.'); + } + + if (project.properties['ccsdk.project.version'].endsWith("-SNAPSHOT")) + { + project.properties['project.docker.latesttag.version']=versionArray[0] + '.' + versionArray[1] + "-STAGING-latest"; + } else { + project.properties['project.docker.latesttag.version']=versionArray[0]+'.' + versionArray[1]+"-STAGING-latest"; + } + + println 'New Tag for docker:' + project.properties['project.docker.latesttag.version']; + + + + + + + io.fabric8 + docker-maven-plugin + 0.26.1 + false + + + + ${image.name} + + try + ${basedir}/target/docker-stage + + ${project.version} + ${project.version}-STAGING-${maven.build.timestamp} + ${project.docker.latesttag.version} + + + + + true + + + + + + + + + + + push-images + deploy + + build + push + + + + + + + + -- cgit 1.2.3-korg From d5510f3133d37b80c0786908e336260a5d75d38a Mon Sep 17 00:00:00 2001 From: "Timoney, Dan (dt5972)" Date: Wed, 12 Sep 2018 15:31:10 -0400 Subject: Control docker build with profile Docker build should only be run if docker profile is enabled. Change-Id: I6942c3e59b769053fd47d04fe98f3e4b95ea33dd Issue-ID: CCSDK-558 Signed-off-by: Timoney, Dan (dt5972) --- ms/controllerblueprints/.gitignore | 3 +- ms/controllerblueprints/application/pom.xml | 2 + ms/controllerblueprints/distribution/pom.xml | 90 +++++++++++++++------------- 3 files changed, 53 insertions(+), 42 deletions(-) (limited to 'ms/controllerblueprints/distribution/pom.xml') diff --git a/ms/controllerblueprints/.gitignore b/ms/controllerblueprints/.gitignore index 644e3b492..8cda363d8 100644 --- a/ms/controllerblueprints/.gitignore +++ b/ms/controllerblueprints/.gitignore @@ -20,4 +20,5 @@ **/*versionsBackup **/blackDuckHub* -**/*.jsonld \ No newline at end of file +**/*.jsonld +/target-ide/ diff --git a/ms/controllerblueprints/application/pom.xml b/ms/controllerblueprints/application/pom.xml index 38f81c169..24f4debe0 100644 --- a/ms/controllerblueprints/application/pom.xml +++ b/ms/controllerblueprints/application/pom.xml @@ -198,5 +198,7 @@ + + diff --git a/ms/controllerblueprints/distribution/pom.xml b/ms/controllerblueprints/distribution/pom.xml index 37c0b8448..7a2c67920 100644 --- a/ms/controllerblueprints/distribution/pom.xml +++ b/ms/controllerblueprints/distribution/pom.xml @@ -34,7 +34,10 @@ org.onap.ccsdk.apps controllerblueprints onap/ccsdk-controllerblueprints - + ${https_proxy} + deploy + true + @@ -141,47 +144,52 @@ - - io.fabric8 - docker-maven-plugin - 0.26.1 - false - - - - ${image.name} - - try - ${basedir}/target/docker-stage - - ${project.version} - ${project.version}-STAGING-${maven.build.timestamp} - ${project.docker.latesttag.version} - - - - - true - - - - - - - - - - - push-images - deploy - - build - push - - - - + + + + + docker + + + + io.fabric8 + docker-maven-plugin + 0.26.1 + false + + + + ${image.name} + + try + ${basedir}/target/docker-stage + + ${project.version} + ${project.version}-STAGING-${maven.build.timestamp} + ${project.docker.latesttag.version} + + + + + true + + + + push-images + ${docker.build.phase} + + build + push + + + + + + + + + -- cgit 1.2.3-korg From c4200f66c92b7cc9331dc5d01773aeda1c4ba989 Mon Sep 17 00:00:00 2001 From: "Timoney, Dan (dt5972)" Date: Thu, 27 Sep 2018 16:26:45 -0400 Subject: Roll to next snapshot version Roll to next snapshot version Change-Id: Ifbbe4c890c47001d60117f09a67daa278d57dcd4 Issue-ID: CCSDK-597 Signed-off-by: Timoney, Dan (dt5972) --- ms/controllerblueprints/application/pom.xml | 2 +- ms/controllerblueprints/distribution/pom.xml | 2 +- ms/controllerblueprints/modules/pom.xml | 2 +- ms/controllerblueprints/modules/service/pom.xml | 2 +- ms/controllerblueprints/parent/pom.xml | 2 +- ms/controllerblueprints/pom.xml | 4 ++-- 6 files changed, 7 insertions(+), 7 deletions(-) (limited to 'ms/controllerblueprints/distribution/pom.xml') diff --git a/ms/controllerblueprints/application/pom.xml b/ms/controllerblueprints/application/pom.xml index 9834924e0..ecb882175 100644 --- a/ms/controllerblueprints/application/pom.xml +++ b/ms/controllerblueprints/application/pom.xml @@ -25,7 +25,7 @@ org.onap.ccsdk.apps.controllerblueprints parent - 0.3.0-SNAPSHOT + 0.3.1-SNAPSHOT ../parent application diff --git a/ms/controllerblueprints/distribution/pom.xml b/ms/controllerblueprints/distribution/pom.xml index 7a2c67920..b2c5b33c4 100644 --- a/ms/controllerblueprints/distribution/pom.xml +++ b/ms/controllerblueprints/distribution/pom.xml @@ -23,7 +23,7 @@ org.onap.ccsdk.apps.controllerblueprints parent - 0.3.0-SNAPSHOT + 0.3.1-SNAPSHOT ../parent distribution diff --git a/ms/controllerblueprints/modules/pom.xml b/ms/controllerblueprints/modules/pom.xml index 887d02331..b38b6e6aa 100644 --- a/ms/controllerblueprints/modules/pom.xml +++ b/ms/controllerblueprints/modules/pom.xml @@ -23,7 +23,7 @@ org.onap.ccsdk.apps.controllerblueprints parent - 0.3.0-SNAPSHOT + 0.3.1-SNAPSHOT ../parent modules diff --git a/ms/controllerblueprints/modules/service/pom.xml b/ms/controllerblueprints/modules/service/pom.xml index e95c1f739..add4ad15a 100644 --- a/ms/controllerblueprints/modules/service/pom.xml +++ b/ms/controllerblueprints/modules/service/pom.xml @@ -25,7 +25,7 @@ org.onap.ccsdk.apps.controllerblueprints modules - 0.3.0-SNAPSHOT + 0.3.1-SNAPSHOT service Controller Blueprints Service diff --git a/ms/controllerblueprints/parent/pom.xml b/ms/controllerblueprints/parent/pom.xml index 86dfdf69c..659839c5e 100644 --- a/ms/controllerblueprints/parent/pom.xml +++ b/ms/controllerblueprints/parent/pom.xml @@ -21,7 +21,7 @@ org.onap.ccsdk.apps controllerblueprints - 0.3.0-SNAPSHOT + 0.3.1-SNAPSHOT org.onap.ccsdk.apps.controllerblueprints parent diff --git a/ms/controllerblueprints/pom.xml b/ms/controllerblueprints/pom.xml index 5c190db5d..d8acbf20f 100644 --- a/ms/controllerblueprints/pom.xml +++ b/ms/controllerblueprints/pom.xml @@ -20,13 +20,13 @@ org.onap.ccsdk.apps ccsdk-apps-ms - 0.3.0-SNAPSHOT + 0.3.1-SNAPSHOT 4.0.0 org.onap.ccsdk.apps controllerblueprints Controller Blueprints Root - 0.3.0-SNAPSHOT + 0.3.1-SNAPSHOT ControllerBlueprints UTF-8 -- cgit 1.2.3-korg From 85b0edf34bac8732fe03ca2ca4e7df35bea6736b Mon Sep 17 00:00:00 2001 From: "Timoney, Dan (dt5972)" Date: Thu, 25 Oct 2018 10:34:51 -0400 Subject: Roll to initial Dublin version Roll to initial Dublin release version Change-Id: I9f56f6643bf5850a9958d46f137fa929b1c05e5d Issue-ID: CCSDK-617 Signed-off-by: Timoney, Dan (dt5972) --- ms/controllerblueprints/application/pom.xml | 2 +- ms/controllerblueprints/distribution/pom.xml | 2 +- ms/controllerblueprints/modules/pom.xml | 2 +- ms/controllerblueprints/modules/service/pom.xml | 2 +- ms/controllerblueprints/parent/pom.xml | 4 ++-- ms/controllerblueprints/pom.xml | 4 ++-- 6 files changed, 8 insertions(+), 8 deletions(-) (limited to 'ms/controllerblueprints/distribution/pom.xml') diff --git a/ms/controllerblueprints/application/pom.xml b/ms/controllerblueprints/application/pom.xml index ecb882175..44fda2dd6 100644 --- a/ms/controllerblueprints/application/pom.xml +++ b/ms/controllerblueprints/application/pom.xml @@ -25,7 +25,7 @@ org.onap.ccsdk.apps.controllerblueprints parent - 0.3.1-SNAPSHOT + 0.4.0-SNAPSHOT ../parent application diff --git a/ms/controllerblueprints/distribution/pom.xml b/ms/controllerblueprints/distribution/pom.xml index b2c5b33c4..498442a25 100644 --- a/ms/controllerblueprints/distribution/pom.xml +++ b/ms/controllerblueprints/distribution/pom.xml @@ -23,7 +23,7 @@ org.onap.ccsdk.apps.controllerblueprints parent - 0.3.1-SNAPSHOT + 0.4.0-SNAPSHOT ../parent distribution diff --git a/ms/controllerblueprints/modules/pom.xml b/ms/controllerblueprints/modules/pom.xml index b38b6e6aa..eff2429ab 100644 --- a/ms/controllerblueprints/modules/pom.xml +++ b/ms/controllerblueprints/modules/pom.xml @@ -23,7 +23,7 @@ org.onap.ccsdk.apps.controllerblueprints parent - 0.3.1-SNAPSHOT + 0.4.0-SNAPSHOT ../parent modules diff --git a/ms/controllerblueprints/modules/service/pom.xml b/ms/controllerblueprints/modules/service/pom.xml index add4ad15a..e766f51cf 100644 --- a/ms/controllerblueprints/modules/service/pom.xml +++ b/ms/controllerblueprints/modules/service/pom.xml @@ -25,7 +25,7 @@ org.onap.ccsdk.apps.controllerblueprints modules - 0.3.1-SNAPSHOT + 0.4.0-SNAPSHOT service Controller Blueprints Service diff --git a/ms/controllerblueprints/parent/pom.xml b/ms/controllerblueprints/parent/pom.xml index 659839c5e..a9e7cfa52 100644 --- a/ms/controllerblueprints/parent/pom.xml +++ b/ms/controllerblueprints/parent/pom.xml @@ -21,7 +21,7 @@ org.onap.ccsdk.apps controllerblueprints - 0.3.1-SNAPSHOT + 0.4.0-SNAPSHOT org.onap.ccsdk.apps.controllerblueprints parent @@ -34,7 +34,7 @@ 1.0.0 2.9.2 1.4.197 - 1.2.2-SNAPSHOT + 1.2.2 diff --git a/ms/controllerblueprints/pom.xml b/ms/controllerblueprints/pom.xml index d8acbf20f..4517f3f3e 100644 --- a/ms/controllerblueprints/pom.xml +++ b/ms/controllerblueprints/pom.xml @@ -20,13 +20,13 @@ org.onap.ccsdk.apps ccsdk-apps-ms - 0.3.1-SNAPSHOT + 0.4.0-SNAPSHOT 4.0.0 org.onap.ccsdk.apps controllerblueprints Controller Blueprints Root - 0.3.1-SNAPSHOT + 0.4.0-SNAPSHOT ControllerBlueprints UTF-8 -- cgit 1.2.3-korg From 14f6e0b3dee03fe5d9687e744cdd428409cb5a12 Mon Sep 17 00:00:00 2001 From: Alexis de Talhouët Date: Thu, 1 Nov 2018 21:12:30 -0400 Subject: Build/deploy ControllerBlueprint Dockerimage MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: Iba3217fe6080f4a1430095ef4c184fe7e9286459 Issue-ID: CCSDK-646 Signed-off-by: Alexis de Talhouët --- ms/controllerblueprints/distribution/pom.xml | 23 +++++++++++++++-------- 1 file changed, 15 insertions(+), 8 deletions(-) (limited to 'ms/controllerblueprints/distribution/pom.xml') diff --git a/ms/controllerblueprints/distribution/pom.xml b/ms/controllerblueprints/distribution/pom.xml index 498442a25..d3bff091b 100644 --- a/ms/controllerblueprints/distribution/pom.xml +++ b/ms/controllerblueprints/distribution/pom.xml @@ -176,14 +176,21 @@ true - - push-images - ${docker.build.phase} - - build - push - - + + generate-images + package + + build + + + + push-images + ${docker.push.phase} + + build + push + + -- cgit 1.2.3-korg From e407c61c8834f714175d2dc9761ae1b99ee0a1ea Mon Sep 17 00:00:00 2001 From: "Muthuramalingam, Brinda Santh(bs2796)" Date: Sat, 10 Nov 2018 18:02:29 -0500 Subject: Controller Blueprints Microservice Change Application Properties and Docker Blueprint model load Parameters. Change-Id: I799cbab4388916c8e07e9453d93214e788a16fa2 Issue-ID: CCSDK-660 Signed-off-by: Muthuramalingam, Brinda Santh(bs2796) --- ms/controllerblueprints/README.md | 1 + .../opt/app/onap/config/application-dev.properties | 62 ++++++++++++++++++++++ .../opt/app/onap/config/application.properties | 12 ++--- ms/controllerblueprints/distribution/pom.xml | 2 +- .../distribution/src/main/dc/docker-compose.yaml | 2 +- .../distribution/src/main/docker/Dockerfile | 2 +- .../distribution/src/main/docker/distribution.xml | 9 +--- .../service/DataBaseInitService.java | 6 +-- 8 files changed, 77 insertions(+), 19 deletions(-) create mode 100644 ms/controllerblueprints/application/opt/app/onap/config/application-dev.properties (limited to 'ms/controllerblueprints/distribution/pom.xml') diff --git a/ms/controllerblueprints/README.md b/ms/controllerblueprints/README.md index 4079daf60..43eeee5fc 100755 --- a/ms/controllerblueprints/README.md +++ b/ms/controllerblueprints/README.md @@ -9,4 +9,5 @@ Application VM Arguments : -Dspring.datasource.username=sdnctl -Dspring.datasource.password=sdnctl -Dblueprints.load.initial-data=true +-Dspring.profiles.active=dev diff --git a/ms/controllerblueprints/application/opt/app/onap/config/application-dev.properties b/ms/controllerblueprints/application/opt/app/onap/config/application-dev.properties new file mode 100644 index 000000000..e09208703 --- /dev/null +++ b/ms/controllerblueprints/application/opt/app/onap/config/application-dev.properties @@ -0,0 +1,62 @@ +# +# Copyright © 2017-2018 AT&T Intellectual Property. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +appName=ControllerBluePrints +ms_name=org.onap.ccsdk.apps.controllerblueprints +appVersion=1.0.0 + +# Basic Authentication +basic-auth.user-name=ccsdkapps +basic-auth.hashed-pwd=$2a$10$MJxhNiOAffxbyrV9.rrOUewP9Q/ASg5Nit2cmP.yBaXGsVXo8BW3y + +#logging.pattern.console=%clr(%d{yyyy-MM-dd HH:mm:ss.SSS}){faint} %clr(%5p) %clr($ threadId: {PID:- }){magenta} %clr(---){faint} %clr([ hostname: %X{hostname} serviceName: %X{serviceName} version: %X{version} transactionId: %X{transactionId} requestTimeStamp: %X{requestTimestamp} responseTimeStamp: %X{responseTimestamp} duration: %X{duration}]){yellow} %clr([%15.15t]){faint} %clr(%-40.40logger{39}){cyan} %clr(:){faint} %m%n%wex + +logging.level.org.springframework.web=INFO +logging.level.org.hibernate.SQL=warn +logging.level.org.hibernate.type.descriptor.sql=debug + +#To Remove Null in JSON API Response +spring.jackson.default-property-inclusion=non_null + +#Swagger Configuration +swagger.contact.name=Brinda Santh Muthuramalingam +swagger.contact.url=www.onap.com +swagger.contact.email=brindasanth@onap.com + +spring.jpa.properties.hibernate.show_sql=true +spring.jpa.properties.hibernate.use_sql_comments=true +spring.jpa.properties.hibernate.format_sql=true + +# spring.datasource.url, spring.datasource.username,spring.datasource.password may be overridden by ENV variables +spring.datasource.url=jdbc:mysql://localhost:3306/sdnctl +spring.datasource.username=sdnctl +spring.datasource.password=sdnctl +spring.datasource.driver-class-name=org.mariadb.jdbc.Driver +spring.jpa.show-sql = true +spring.jpa.hibernate.ddl-auto = none +spring.jpa.hibernate.naming-strategy = org.hibernate.cfg.ImprovedNamingStrategy +spring.jpa.properties.hibernate.dialect = org.hibernate.dialect.MySQL5InnoDBDialect + +#Load Blueprints +# blueprints.load.initial-data may be overridden by ENV variables +blueprints.load.initial-data=true +load.dataTypePath=./../../../components/model-catalog/definition-type/starter-type/data_type +load.nodeTypePath=./../../../components/model-catalog/definition-type/starter-type/node_type +load.artifactTypePath=./../../../components/model-catalog/definition-type/starter-type/artifact_type +load.resourceDictionaryPath=./../../../components/model-catalog/resource-dictionary/starter-dictionary +load.blueprintsPath=./../../../components/model-catalog/blueprint-model/starter-blueprint + +# Load Resource Source Mappings +resourceSourceMappings=db=source-db,input=source-input,default=source-default,mdsal=source-rest \ No newline at end of file diff --git a/ms/controllerblueprints/application/opt/app/onap/config/application.properties b/ms/controllerblueprints/application/opt/app/onap/config/application.properties index c0588c869..0160ee5fb 100644 --- a/ms/controllerblueprints/application/opt/app/onap/config/application.properties +++ b/ms/controllerblueprints/application/opt/app/onap/config/application.properties @@ -52,12 +52,12 @@ spring.jpa.properties.hibernate.dialect = org.hibernate.dialect.MySQL5InnoDBDial #Load Blueprints # blueprints.load.initial-data may be overridden by ENV variables -blueprints.load.initial-data=false -load.dataTypePath=load/model_type/data_type -load.nodeTypePath=load/model_type/node_type -load.artifactTypePath=load/model_type/artifact_type -load.resourceDictionaryPath=load/resource_dictionary -load.blueprintsPath=load/blueprints +blueprints.load.initial-data=true +load.dataTypePath=model-catalog/definition-type/starter-type/data_type +load.nodeTypePath=model-catalog/definition-type/starter-type/node_type +load.artifactTypePath=model-catalog/definition-type/starter-type/artifact_type +load.resourceDictionaryPath=model-catalog/resource-dictionary/starter-dictionary +load.blueprintsPath=model-catalog/blueprint-model/starter-blueprint # Load Resource Source Mappings resourceSourceMappings=db=source-db,input=source-input,default=source-default,mdsal=source-rest \ No newline at end of file diff --git a/ms/controllerblueprints/distribution/pom.xml b/ms/controllerblueprints/distribution/pom.xml index d3bff091b..33690024b 100644 --- a/ms/controllerblueprints/distribution/pom.xml +++ b/ms/controllerblueprints/distribution/pom.xml @@ -94,7 +94,7 @@ maven-assembly-plugin - 3.0.0 + 3.1.0 ${basedir}/target/docker-stage diff --git a/ms/controllerblueprints/distribution/src/main/dc/docker-compose.yaml b/ms/controllerblueprints/distribution/src/main/dc/docker-compose.yaml index 3c1464699..dd2190843 100644 --- a/ms/controllerblueprints/distribution/src/main/dc/docker-compose.yaml +++ b/ms/controllerblueprints/distribution/src/main/dc/docker-compose.yaml @@ -5,7 +5,7 @@ services: image: mariadb:latest container_name: cb-mariadb ports: - - "3307:3306" + - "3306:3306" volumes: - ~/vm_mysql:/var/lib/mysql restart: always diff --git a/ms/controllerblueprints/distribution/src/main/docker/Dockerfile b/ms/controllerblueprints/distribution/src/main/docker/Dockerfile index a2f453f24..6de589dac 100644 --- a/ms/controllerblueprints/distribution/src/main/docker/Dockerfile +++ b/ms/controllerblueprints/distribution/src/main/docker/Dockerfile @@ -14,7 +14,7 @@ RUN (mkdir -p /source /opt/app/onap) && (tar -xzf /source.tar.gz -C /source) \ && (mv /source/@project.build.finalName@ /source/app) \ && (cp -rf /source/app/opt/app/onap/lib /opt/app/onap/) \ && (cp -rf /source/app/etc /) \ -&& (cp -rf /source/app/load /) \ +&& (cp -rf /source/app/model-catalog /) \ && (rm -rf /source) ENTRYPOINT /startService.sh diff --git a/ms/controllerblueprints/distribution/src/main/docker/distribution.xml b/ms/controllerblueprints/distribution/src/main/docker/distribution.xml index f2f3cb0be..c929f98ef 100644 --- a/ms/controllerblueprints/distribution/src/main/docker/distribution.xml +++ b/ms/controllerblueprints/distribution/src/main/docker/distribution.xml @@ -48,11 +48,6 @@ ./ true - - ${project.basedir}/../application/src/main/groovy - src/main/groovy - true - ${project.basedir}/../application/src/main/resources src/main/resources @@ -64,8 +59,8 @@ true - ${project.basedir}/../application/load - load + ${project.basedir}/../../../components/model-catalog + ./model-catalog true diff --git a/ms/controllerblueprints/modules/service/src/main/java/org/onap/ccsdk/apps/controllerblueprints/service/DataBaseInitService.java b/ms/controllerblueprints/modules/service/src/main/java/org/onap/ccsdk/apps/controllerblueprints/service/DataBaseInitService.java index cfcf93d29..92fe8def0 100644 --- a/ms/controllerblueprints/modules/service/src/main/java/org/onap/ccsdk/apps/controllerblueprints/service/DataBaseInitService.java +++ b/ms/controllerblueprints/modules/service/src/main/java/org/onap/ccsdk/apps/controllerblueprints/service/DataBaseInitService.java @@ -39,11 +39,11 @@ import com.att.eelf.configuration.EELFManager; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Value; import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty; +import org.springframework.boot.context.event.ApplicationReadyEvent; +import org.springframework.context.event.EventListener; import org.springframework.core.io.Resource; import org.springframework.core.io.support.ResourcePatternResolver; import org.springframework.stereotype.Component; - -import javax.annotation.PostConstruct; import java.io.IOException; import java.nio.charset.Charset; import java.util.List; @@ -94,8 +94,8 @@ public class DataBaseInitService { } - @PostConstruct @SuppressWarnings("unused") + @EventListener(ApplicationReadyEvent.class) private void initDatabase() { log.info("loading dataTypePath from DIR : {}", dataTypePath); log.info("loading nodeTypePath from DIR : {}", nodeTypePath); -- cgit 1.2.3-korg From ad9f4aec4cc149e760f6b0094b287ff6c32938b4 Mon Sep 17 00:00:00 2001 From: "Timoney, Dan (dt5972)" Date: Tue, 8 Jan 2019 14:40:54 -0500 Subject: Prepare for release build Prepare for release of early ODL-Oxygen based CCSDK Dublin Change-Id: I63929ef52de41309905ee31e3fbcf49b64063059 Issue-ID: CCSDK-870 Signed-off-by: Timoney, Dan (dt5972) --- ms/controllerblueprints/application/pom.xml | 514 +++++++++++++-------------- ms/controllerblueprints/distribution/pom.xml | 398 ++++++++++----------- ms/controllerblueprints/pom.xml | 5 +- 3 files changed, 451 insertions(+), 466 deletions(-) (limited to 'ms/controllerblueprints/distribution/pom.xml') diff --git a/ms/controllerblueprints/application/pom.xml b/ms/controllerblueprints/application/pom.xml index bb0f7686d..bd244e0db 100644 --- a/ms/controllerblueprints/application/pom.xml +++ b/ms/controllerblueprints/application/pom.xml @@ -1,260 +1,254 @@ - - - - - 4.0.0 - - org.onap.ccsdk.apps.controllerblueprints - parent - 0.4.0-SNAPSHOT - ../parent - - application - Controller Blueprints Application - - ${basedir}/target/src/main/resources/swagger-ui - 1.8 - org.onap.ccsdk.apps - controllerblueprints - - jacoco - reuseReports - ${basedir}/target/surefire-reports - ${basedir}/target/failsafe-reports - ${basedir}/target/jacoco_report - ${basedir}/target/jacoco_itReport - ${basedir}/target/jacoco-ut.exec - ${basedir}/target/jacoco-it.exec - java - 2.0.7 - - - - - org.onap.ccsdk.apps.controllerblueprints - service - - - org.springframework.boot - spring-boot-starter-security - - - org.springframework.boot - spring-boot-starter-actuator - - - org.powermock - powermock-api-mockito2 - test - - - org.springframework.boot - spring-boot-starter-test - test - - - org.springframework.security - spring-security-test - test - - - org.jetbrains.kotlin - kotlin-test-junit - test - - - io.projectreactor - reactor-test - test - - - - - - - ${basedir}/etc - ${basedir}/target/etc - true - - **/* - - - - - ${basedir}/src/main/resources - ${basedir}/target/src/main/resources - true - - **/* - - - - src/main/resources - - **/* - - true - - - - - maven-resources-plugin - 2.6 - - - copy-dockerfile - - copy-resources - - validate - - ${basedir}/target/docker-stage - - - src/main/docker - - * - - true - - - - - - - - - org.jacoco - jacoco-maven-plugin - 0.7.5.201505241946 - - - - pre-unit-test - - prepare-agent - - - - ${sonar.jacoco.reportPath} - surefireArgLine - - - - - post-unit-test - test - - report - - - - ${sonar.jacoco.reportPath} - - ${jacoco.path} - - - - - - org.apache.maven.plugins - maven-antrun-plugin - - - ant-test - package - - - - - - - run - - - - - - maven-compiler-plugin - 3.1 - - - 1.8 - 1.8 - - - - com.github.kongchen - swagger-maven-plugin - 3.1.7 - - - - true - org.onap.ccsdk.apps.controllerblueprints.service.rs - - - http - https - - /api/v1 - - Controller Blueprints - ${project.version} - - Controller blueprints API for VNF Self Service. - - - Terms of service - - - brindasanth@gmail.com - Brinda Santh - http://onap.com - - - http://www.apache.org/licenses/LICENSE-2.0.html - Apache 2.0 - - - ${swagger.directory} - - - - - - compile - - generate - - - - - - - - - - + + + + 4.0.0 + + org.onap.ccsdk.apps.controllerblueprints + parent + 0.4.0-SNAPSHOT + ../parent + + application + Controller Blueprints Application + + ${basedir}/target/src/main/resources/swagger-ui + 1.8 + org.onap.ccsdk.apps + controllerblueprints + + jacoco + reuseReports + ${basedir}/target/surefire-reports + ${basedir}/target/failsafe-reports + ${basedir}/target/jacoco_report + ${basedir}/target/jacoco_itReport + ${basedir}/target/jacoco-ut.exec + ${basedir}/target/jacoco-it.exec + java + 2.0.7 + + + + + org.onap.ccsdk.apps.controllerblueprints + service + + + org.springframework.boot + spring-boot-starter-security + + + org.springframework.boot + spring-boot-starter-actuator + + + org.powermock + powermock-api-mockito2 + test + + + org.springframework.boot + spring-boot-starter-test + test + + + org.springframework.security + spring-security-test + test + + + org.jetbrains.kotlin + kotlin-test-junit + test + + + io.projectreactor + reactor-test + test + + + + + + + ${basedir}/etc + ${basedir}/target/etc + true + + **/* + + + + + ${basedir}/src/main/resources + ${basedir}/target/src/main/resources + true + + **/* + + + + src/main/resources + + **/* + + true + + + + + maven-resources-plugin + 2.6 + + + copy-dockerfile + + copy-resources + + validate + + ${basedir}/target/docker-stage + + + src/main/docker + + * + + true + + + + + + + + + org.jacoco + jacoco-maven-plugin + 0.7.5.201505241946 + + + + pre-unit-test + + prepare-agent + + + + ${sonar.jacoco.reportPath} + surefireArgLine + + + + + post-unit-test + test + + report + + + + ${sonar.jacoco.reportPath} + + ${jacoco.path} + + + + + + org.apache.maven.plugins + maven-antrun-plugin + + + ant-test + package + + + + + + + run + + + + + + maven-compiler-plugin + 3.1 + + + 1.8 + 1.8 + + + + com.github.kongchen + swagger-maven-plugin + 3.1.7 + + + + true + org.onap.ccsdk.apps.controllerblueprints.service.rs + + + http + https + + /api/v1 + + Controller Blueprints + ${project.version} + + Controller blueprints API for VNF Self Service. + + + Terms of service + + + brindasanth@gmail.com + Brinda Santh + http://onap.com + + + http://www.apache.org/licenses/LICENSE-2.0.html + Apache 2.0 + + + ${swagger.directory} + + + + + + compile + + generate + + + + + + + + + diff --git a/ms/controllerblueprints/distribution/pom.xml b/ms/controllerblueprints/distribution/pom.xml index 33690024b..afbc6617a 100644 --- a/ms/controllerblueprints/distribution/pom.xml +++ b/ms/controllerblueprints/distribution/pom.xml @@ -1,202 +1,196 @@ - - - - - 4.0.0 - - org.onap.ccsdk.apps.controllerblueprints - parent - 0.4.0-SNAPSHOT - ../parent - - distribution - pom - Controller Blueprints Distribution - - maven - org.onap.ccsdk.apps - controllerblueprints - onap/ccsdk-controllerblueprints - ${https_proxy} - deploy - true - - - - - org.onap.ccsdk.apps.controllerblueprints - application - - - - - - maven-resources-plugin - 2.6 - - - copy-dockerfile - - copy-resources - - validate - - ${basedir}/target/docker-stage - - - src/main/docker - - * - - true - - - - - - - - org.apache.maven.plugins - maven-antrun-plugin - - - ant-test - package - - - - - - - run - - - - - - - maven-assembly-plugin - 3.1.0 - - - ${basedir}/target/docker-stage - - src/main/docker/distribution.xml - - posix - - - - ${assembly.id} - package - - single - - - - - - org.codehaus.groovy.maven - gmaven-plugin - 1.0 - - - validate - - execute - - - - println project.properties['ccsdk.project.version']; - def versionArray; - if (project.properties['ccsdk.project.version'] != null ) { - versionArray = project.properties['ccsdk.project.version'].split('\\.'); - } - - if (project.properties['ccsdk.project.version'].endsWith("-SNAPSHOT")) - { - project.properties['project.docker.latesttag.version']=versionArray[0] + '.' + versionArray[1] + "-STAGING-latest"; - } else { - project.properties['project.docker.latesttag.version']=versionArray[0]+'.' + versionArray[1]+"-STAGING-latest"; - } - - println 'New Tag for docker:' + project.properties['project.docker.latesttag.version']; - - - - - - - - - - - - docker - - - - io.fabric8 - docker-maven-plugin - 0.26.1 - false - - - - ${image.name} - - try - ${basedir}/target/docker-stage - - ${project.version} - ${project.version}-STAGING-${maven.build.timestamp} - ${project.docker.latesttag.version} - - - - - true - - - - generate-images - package - - build - - - - push-images - ${docker.push.phase} - - build - push - - - - - - - - - - - + + + + 4.0.0 + + org.onap.ccsdk.apps.controllerblueprints + parent + 0.4.0-SNAPSHOT + ../parent + + distribution + pom + Controller Blueprints Distribution + + maven + org.onap.ccsdk.apps + controllerblueprints + onap/ccsdk-controllerblueprints + ${https_proxy} + deploy + true + + + + + org.onap.ccsdk.apps.controllerblueprints + application + + + + + + maven-resources-plugin + 2.6 + + + copy-dockerfile + + copy-resources + + validate + + ${basedir}/target/docker-stage + + + src/main/docker + + * + + true + + + + + + + + org.apache.maven.plugins + maven-antrun-plugin + + + ant-test + package + + + + + + + run + + + + + + + maven-assembly-plugin + 3.1.0 + + + ${basedir}/target/docker-stage + + src/main/docker/distribution.xml + + posix + + + + ${assembly.id} + package + + single + + + + + + org.codehaus.groovy.maven + gmaven-plugin + 1.0 + + + validate + + execute + + + + println project.properties['ccsdk.project.version']; + def versionArray; + if (project.properties['ccsdk.project.version'] != null ) { + versionArray = project.properties['ccsdk.project.version'].split('\\.'); + } + + if (project.properties['ccsdk.project.version'].endsWith("-SNAPSHOT")) + { + project.properties['project.docker.latesttag.version']=versionArray[0] + '.' + versionArray[1] + "-STAGING-latest"; + } else { + project.properties['project.docker.latesttag.version']=versionArray[0]+'.' + versionArray[1]+"-STAGING-latest"; + } + + println 'New Tag for docker:' + project.properties['project.docker.latesttag.version']; + + + + + + + + + + + + docker + + + + io.fabric8 + docker-maven-plugin + 0.26.1 + false + + + + ${image.name} + + try + ${basedir}/target/docker-stage + + ${project.version} + ${project.version}-STAGING-${maven.build.timestamp} + ${project.docker.latesttag.version} + + + + + true + + + + generate-images + package + + build + + + + push-images + ${docker.push.phase} + + build + push + + + + + + + + + + diff --git a/ms/controllerblueprints/pom.xml b/ms/controllerblueprints/pom.xml index aeff4db9d..d88956f0d 100644 --- a/ms/controllerblueprints/pom.xml +++ b/ms/controllerblueprints/pom.xml @@ -14,9 +14,7 @@ ~ See the License for the specific language governing permissions and ~ limitations under the License. --> - - + org.onap.ccsdk.apps ccsdk-apps-ms @@ -45,4 +43,3 @@ distribution - -- cgit 1.2.3-korg From 13f58213dff9f0297b95a79f38991a57a12f2e1e Mon Sep 17 00:00:00 2001 From: "Timoney, Dan (dt5972)" Date: Fri, 4 Jan 2019 10:43:33 -0500 Subject: Update to use correct parent pom Updated neng microservice to use springboot v1 parent as opposed to odlparent. Without that change, javadoc was failing when compiled with Fluorine version of odlparent-lite parent pom. Change-Id: I677278d90869f493c281c7c5432b271dd43e7513 Issue-ID: CCSDK-870 Signed-off-by: Timoney, Dan (dt5972) --- ms/controllerblueprints/application/pom.xml | 2 +- ms/controllerblueprints/distribution/pom.xml | 2 +- .../modules/blueprint-validation/pom.xml | 9 +- .../modules/db-resources/pom.xml | 9 +- ms/controllerblueprints/modules/pom.xml | 103 ++++++++++----------- ms/controllerblueprints/modules/service/pom.xml | 9 +- ms/controllerblueprints/parent/pom.xml | 2 +- ms/controllerblueprints/pom.xml | 4 +- 8 files changed, 60 insertions(+), 80 deletions(-) (limited to 'ms/controllerblueprints/distribution/pom.xml') diff --git a/ms/controllerblueprints/application/pom.xml b/ms/controllerblueprints/application/pom.xml index bd244e0db..a01a61347 100644 --- a/ms/controllerblueprints/application/pom.xml +++ b/ms/controllerblueprints/application/pom.xml @@ -21,7 +21,7 @@ org.onap.ccsdk.apps.controllerblueprints parent - 0.4.0-SNAPSHOT + 0.4.1-SNAPSHOT ../parent application diff --git a/ms/controllerblueprints/distribution/pom.xml b/ms/controllerblueprints/distribution/pom.xml index afbc6617a..305712936 100644 --- a/ms/controllerblueprints/distribution/pom.xml +++ b/ms/controllerblueprints/distribution/pom.xml @@ -19,7 +19,7 @@ org.onap.ccsdk.apps.controllerblueprints parent - 0.4.0-SNAPSHOT + 0.4.1-SNAPSHOT ../parent distribution diff --git a/ms/controllerblueprints/modules/blueprint-validation/pom.xml b/ms/controllerblueprints/modules/blueprint-validation/pom.xml index 0cafc9a65..d175eecf2 100644 --- a/ms/controllerblueprints/modules/blueprint-validation/pom.xml +++ b/ms/controllerblueprints/modules/blueprint-validation/pom.xml @@ -16,16 +16,12 @@ ~ See the License for the specific language governing permissions and ~ limitations under the License. --> - - + 4.0.0 org.onap.ccsdk.apps.controllerblueprints modules - 0.4.0-SNAPSHOT + 0.4.1-SNAPSHOT blueprint-validation Controller Blueprints Validation Service @@ -49,4 +45,3 @@ - diff --git a/ms/controllerblueprints/modules/db-resources/pom.xml b/ms/controllerblueprints/modules/db-resources/pom.xml index 69e322e40..c09d96c10 100644 --- a/ms/controllerblueprints/modules/db-resources/pom.xml +++ b/ms/controllerblueprints/modules/db-resources/pom.xml @@ -16,16 +16,12 @@ ~ See the License for the specific language governing permissions and ~ limitations under the License. --> - - + 4.0.0 org.onap.ccsdk.apps.controllerblueprints modules - 0.4.0-SNAPSHOT + 0.4.1-SNAPSHOT db-resources Controller Blueprints DB Resources @@ -44,4 +40,3 @@ - diff --git a/ms/controllerblueprints/modules/pom.xml b/ms/controllerblueprints/modules/pom.xml index 9a53eebf3..3857ef5db 100644 --- a/ms/controllerblueprints/modules/pom.xml +++ b/ms/controllerblueprints/modules/pom.xml @@ -1,54 +1,49 @@ - - - - - 4.0.0 - - org.onap.ccsdk.apps.controllerblueprints - parent - 0.4.0-SNAPSHOT - ../parent - - modules - Controller Blueprints Modules - pom - - - service - blueprint-validation - db-resources - - - - - - maven-compiler-plugin - 3.1 - - - 1.8 - 1.8 - - - - - - - + + + + 4.0.0 + + org.onap.ccsdk.apps.controllerblueprints + parent + 0.4.1-SNAPSHOT + ../parent + + modules + Controller Blueprints Modules + pom + + + service + blueprint-validation + db-resources + + + + + + maven-compiler-plugin + 3.1 + + + 1.8 + 1.8 + + + + + + diff --git a/ms/controllerblueprints/modules/service/pom.xml b/ms/controllerblueprints/modules/service/pom.xml index 91a9eab14..9868b17be 100644 --- a/ms/controllerblueprints/modules/service/pom.xml +++ b/ms/controllerblueprints/modules/service/pom.xml @@ -16,16 +16,12 @@ ~ See the License for the specific language governing permissions and ~ limitations under the License. --> - - + 4.0.0 org.onap.ccsdk.apps.controllerblueprints modules - 0.4.0-SNAPSHOT + 0.4.1-SNAPSHOT service Controller Blueprints Service @@ -93,4 +89,3 @@ - diff --git a/ms/controllerblueprints/parent/pom.xml b/ms/controllerblueprints/parent/pom.xml index ec6f25239..ea93bb21f 100644 --- a/ms/controllerblueprints/parent/pom.xml +++ b/ms/controllerblueprints/parent/pom.xml @@ -21,7 +21,7 @@ org.onap.ccsdk.apps controllerblueprints - 0.4.0-SNAPSHOT + 0.4.1-SNAPSHOT org.onap.ccsdk.apps.controllerblueprints parent diff --git a/ms/controllerblueprints/pom.xml b/ms/controllerblueprints/pom.xml index d88956f0d..6d6dae6ba 100644 --- a/ms/controllerblueprints/pom.xml +++ b/ms/controllerblueprints/pom.xml @@ -18,12 +18,12 @@ org.onap.ccsdk.apps ccsdk-apps-ms - 0.4.0-SNAPSHOT + 0.4.1-SNAPSHOT 4.0.0 controllerblueprints Controller Blueprints Root - 0.4.0-SNAPSHOT + 0.4.1-SNAPSHOT ControllerBlueprints UTF-8 -- cgit 1.2.3-korg From 252e13314785fb91003adcb9902a5f8dc8d86683 Mon Sep 17 00:00:00 2001 From: Steve Alphonse Siani Date: Mon, 21 Jan 2019 11:55:48 -0500 Subject: ControllerBlueprint blueprintsProcessor container Change-Id: I77df77757c276fca705091c1566c386f842269c4 Issue-ID: CCSDK-949 Signed-off-by: Steve Alphonse Siani --- ms/controllerblueprints/application/etc/run.source | 5 +- .../opt/app/onap/config/application-dev.properties | 5 +- .../opt/app/onap/config/application.properties | 22 +++--- .../application/opt/app/onap/config/logback.xml | 44 +++++++++++ .../controllerblueprints/ApplicationConstants.java | 2 +- .../ControllerBlueprintsApplication.java | 42 ++++++++++ .../ControllerBluprintsApplication.java | 42 ---------- .../src/main/resources/application-dev.properties | 70 +++++++++++++++++ .../src/main/resources/application.properties | 74 ++++++++++++++++++ .../ControllerBlueprintsApplicationTest.java | 62 +++++++++++++++ .../ControllerBluprintsApplicationTest.java | 62 --------------- .../src/test/resources/application.properties | 5 +- ms/controllerblueprints/distribution/pom.xml | 89 +++++++++++----------- .../distribution/src/main/dc/docker-compose.yaml | 70 ++++++++--------- .../distribution/src/main/docker/Dockerfile | 3 +- .../distribution/src/main/docker/distribution.xml | 6 ++ .../distribution/src/main/docker/startService.sh | 1 + 17 files changed, 402 insertions(+), 202 deletions(-) mode change 100644 => 100755 ms/controllerblueprints/application/etc/run.source create mode 100755 ms/controllerblueprints/application/opt/app/onap/config/logback.xml create mode 100644 ms/controllerblueprints/application/src/main/java/org/onap/ccsdk/apps/controllerblueprints/ControllerBlueprintsApplication.java delete mode 100644 ms/controllerblueprints/application/src/main/java/org/onap/ccsdk/apps/controllerblueprints/ControllerBluprintsApplication.java create mode 100755 ms/controllerblueprints/application/src/main/resources/application-dev.properties create mode 100755 ms/controllerblueprints/application/src/main/resources/application.properties create mode 100644 ms/controllerblueprints/application/src/test/java/org/onap/ccsdk/apps/controllerblueprints/ControllerBlueprintsApplicationTest.java delete mode 100644 ms/controllerblueprints/application/src/test/java/org/onap/ccsdk/apps/controllerblueprints/ControllerBluprintsApplicationTest.java mode change 100644 => 100755 ms/controllerblueprints/distribution/pom.xml mode change 100644 => 100755 ms/controllerblueprints/distribution/src/main/dc/docker-compose.yaml mode change 100644 => 100755 ms/controllerblueprints/distribution/src/main/docker/Dockerfile mode change 100644 => 100755 ms/controllerblueprints/distribution/src/main/docker/distribution.xml mode change 100644 => 100755 ms/controllerblueprints/distribution/src/main/docker/startService.sh (limited to 'ms/controllerblueprints/distribution/pom.xml') diff --git a/ms/controllerblueprints/application/etc/run.source b/ms/controllerblueprints/application/etc/run.source old mode 100644 new mode 100755 index fc1b4e554..1d0ac0708 --- a/ms/controllerblueprints/application/etc/run.source +++ b/ms/controllerblueprints/application/etc/run.source @@ -9,8 +9,5 @@ java -classpath "/etc:${APP_HOME}/lib/*:/lib/*:/src:/schema:/generated-sources:$ -Djava.security.egd=file:/dev/./urandom \ -DAPPNAME=${APP_NAME} -DAPPENV=${APP_ENV} -DAPPVERSION=${APP_VERSION} -DNAMESPACE=${NAMESPACE} \ -Dspring.config.location=${APP_CONFIG_HOME}/ \ --Dspring.datasource.url=${DB_URL} \ --Dspring.datasource.username=${DB_USER} \ --Dspring.datasource.password=${DB_PASSWORD} \ -Dblueprints.load.initial-data=${INIT_DATA_LOAD} \ -org.onap.ccsdk.apps.controllerblueprints.ControllerBluprintsApplication +org.onap.ccsdk.apps.controllerblueprints.ControllerBlueprintsApplication diff --git a/ms/controllerblueprints/application/opt/app/onap/config/application-dev.properties b/ms/controllerblueprints/application/opt/app/onap/config/application-dev.properties index 1a90df28a..81b3061aa 100755 --- a/ms/controllerblueprints/application/opt/app/onap/config/application-dev.properties +++ b/ms/controllerblueprints/application/opt/app/onap/config/application-dev.properties @@ -64,4 +64,7 @@ controllerblueprints.loadResourceDictionary=true controllerblueprints.loadResourceDictionaryPaths=./../../../components/model-catalog/resource-dictionary/starter-dictionary # CBA file extension -controllerblueprints.loadCbaExtension=zip \ No newline at end of file +controllerblueprints.loadCbaExtension=zip + +# Web server config +server.port=8080 \ No newline at end of file diff --git a/ms/controllerblueprints/application/opt/app/onap/config/application.properties b/ms/controllerblueprints/application/opt/app/onap/config/application.properties index 8d4dd5815..5b651e661 100755 --- a/ms/controllerblueprints/application/opt/app/onap/config/application.properties +++ b/ms/controllerblueprints/application/opt/app/onap/config/application.properties @@ -1,6 +1,7 @@ # # Copyright © 2017-2018 AT&T Intellectual Property. # Modifications Copyright © 2018 IBM. +# Modifications Copyright © 2019 Bell Canada. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -41,14 +42,14 @@ spring.jpa.properties.hibernate.use_sql_comments=true spring.jpa.properties.hibernate.format_sql=true # spring.datasource.url, spring.datasource.username,spring.datasource.password may be overridden by ENV variables -spring.datasource.url=jdbc:mysql://localhost:3306/sdnctl +spring.datasource.url=jdbc:mysql://db:3306/sdnctl spring.datasource.username=sdnctl spring.datasource.password=sdnctl spring.datasource.driver-class-name=org.mariadb.jdbc.Driver -spring.jpa.show-sql = true -spring.jpa.hibernate.ddl-auto = none -spring.jpa.hibernate.naming-strategy = org.hibernate.cfg.ImprovedNamingStrategy -spring.jpa.properties.hibernate.dialect = org.hibernate.dialect.MySQL5InnoDBDialect +spring.jpa.show-sql=true +spring.jpa.hibernate.ddl-auto=none +spring.jpa.hibernate.naming-strategy=org.hibernate.cfg.ImprovedNamingStrategy +spring.jpa.properties.hibernate.dialect=org.hibernate.dialect.MySQL5InnoDBDialect # Load Resource Source Mappings resourceSourceMappings=primary-db=source-primary-db,input=source-input,default=source-default,primary-config-data=source-rest,capability=source-capability @@ -61,11 +62,14 @@ controllerblueprints.blueprintEnrichmentPath=/etc/blueprints/enrichment # blueprints.load.initial-data may be overridden by ENV variables controllerblueprints.loadInitialData=true controllerblueprints.loadBluePrint=false -controllerblueprints.loadBluePrintPaths=model-catalog/blueprint-model/starter-blueprint +controllerblueprints.loadBluePrintPaths=/model-catalog/blueprint-model/starter-blueprint controllerblueprints.loadModelType=true -controllerblueprints.loadModeTypePaths=model-catalog/definition-type/starter-type +controllerblueprints.loadModeTypePaths=/model-catalog/definition-type/starter-type controllerblueprints.loadResourceDictionary=true -controllerblueprints.loadResourceDictionaryPaths=model-catalog/resource-dictionary/starter-dictionary +controllerblueprints.loadResourceDictionaryPaths=/model-catalog/resource-dictionary/starter-dictionary # CBA file extension -controllerblueprints.loadCbaExtension=zip \ No newline at end of file +controllerblueprints.loadCbaExtension=zip + +# Web server config +server.port=8080 \ No newline at end of file diff --git a/ms/controllerblueprints/application/opt/app/onap/config/logback.xml b/ms/controllerblueprints/application/opt/app/onap/config/logback.xml new file mode 100755 index 000000000..01ae4f6c9 --- /dev/null +++ b/ms/controllerblueprints/application/opt/app/onap/config/logback.xml @@ -0,0 +1,44 @@ + + + + + + + + + + + + + + ${defaultPattern} + + + + + + + + + + + + + + + diff --git a/ms/controllerblueprints/application/src/main/java/org/onap/ccsdk/apps/controllerblueprints/ApplicationConstants.java b/ms/controllerblueprints/application/src/main/java/org/onap/ccsdk/apps/controllerblueprints/ApplicationConstants.java index 2471bd5bc..c4759b568 100644 --- a/ms/controllerblueprints/application/src/main/java/org/onap/ccsdk/apps/controllerblueprints/ApplicationConstants.java +++ b/ms/controllerblueprints/application/src/main/java/org/onap/ccsdk/apps/controllerblueprints/ApplicationConstants.java @@ -17,7 +17,7 @@ package org.onap.ccsdk.apps.controllerblueprints; /** - * ApplicationConstants.java Purpose: Provide ControllerBluprintsApplication Constant Information + * ApplicationConstants.java Purpose: Provide ControllerBlueprintsApplication Constant Information * * @author Brinda Santh * @version 1.0 diff --git a/ms/controllerblueprints/application/src/main/java/org/onap/ccsdk/apps/controllerblueprints/ControllerBlueprintsApplication.java b/ms/controllerblueprints/application/src/main/java/org/onap/ccsdk/apps/controllerblueprints/ControllerBlueprintsApplication.java new file mode 100644 index 000000000..e925c69c0 --- /dev/null +++ b/ms/controllerblueprints/application/src/main/java/org/onap/ccsdk/apps/controllerblueprints/ControllerBlueprintsApplication.java @@ -0,0 +1,42 @@ +/* + * Copyright © 2017-2018 AT&T Intellectual Property. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.onap.ccsdk.apps.controllerblueprints; + +import com.att.eelf.configuration.EELFLogger; +import com.att.eelf.configuration.EELFManager; +import org.springframework.boot.SpringApplication; +import org.springframework.boot.autoconfigure.EnableAutoConfiguration; +import org.springframework.boot.autoconfigure.SpringBootApplication; +import org.springframework.context.annotation.ComponentScan; +import org.springframework.web.reactive.config.EnableWebFlux; + +/** + * @author Brinda Santh + */ +@SpringBootApplication +@EnableWebFlux +@ComponentScan(basePackages = {"org.onap.ccsdk.apps.controllerblueprints"}) +@EnableAutoConfiguration +public class ControllerBlueprintsApplication { + private static EELFLogger log = EELFManager.getInstance().getLogger(ControllerBlueprintsApplication.class); + + public static void main(String[] args) { + log.info("****** Starting Controlled Blueprints Application ******"); + SpringApplication.run(ControllerBlueprintsApplication.class, args); + } + +} \ No newline at end of file diff --git a/ms/controllerblueprints/application/src/main/java/org/onap/ccsdk/apps/controllerblueprints/ControllerBluprintsApplication.java b/ms/controllerblueprints/application/src/main/java/org/onap/ccsdk/apps/controllerblueprints/ControllerBluprintsApplication.java deleted file mode 100644 index 6b0efd87b..000000000 --- a/ms/controllerblueprints/application/src/main/java/org/onap/ccsdk/apps/controllerblueprints/ControllerBluprintsApplication.java +++ /dev/null @@ -1,42 +0,0 @@ -/* - * Copyright © 2017-2018 AT&T Intellectual Property. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package org.onap.ccsdk.apps.controllerblueprints; - -import com.att.eelf.configuration.EELFLogger; -import com.att.eelf.configuration.EELFManager; -import org.springframework.boot.SpringApplication; -import org.springframework.boot.autoconfigure.EnableAutoConfiguration; -import org.springframework.boot.autoconfigure.SpringBootApplication; -import org.springframework.context.annotation.ComponentScan; -import org.springframework.web.reactive.config.EnableWebFlux; - -/** - * @author Brinda Santh - */ -@SpringBootApplication -@EnableWebFlux -@ComponentScan(basePackages = {"org.onap.ccsdk.apps.controllerblueprints"}) -@EnableAutoConfiguration -public class ControllerBluprintsApplication { - private static EELFLogger log = EELFManager.getInstance().getLogger(ControllerBluprintsApplication.class); - - public static void main(String[] args) { - log.info("****** Starting Controlled Blueprints Application ******"); - SpringApplication.run(ControllerBluprintsApplication.class, args); - } - -} \ No newline at end of file diff --git a/ms/controllerblueprints/application/src/main/resources/application-dev.properties b/ms/controllerblueprints/application/src/main/resources/application-dev.properties new file mode 100755 index 000000000..30b71fb41 --- /dev/null +++ b/ms/controllerblueprints/application/src/main/resources/application-dev.properties @@ -0,0 +1,70 @@ +# +# Copyright © 2017-2018 AT&T Intellectual Property. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +appName=ControllerBluePrints +ms_name=org.onap.ccsdk.apps.controllerblueprints +appVersion=1.0.0 + +# Basic Authentication +basic-auth.user-name=ccsdkapps +basic-auth.hashed-pwd={bcrypt}$2a$10$MJxhNiOAffxbyrV9.rrOUewP9Q/ASg5Nit2cmP.yBaXGsVXo8BW3y + +#logging.pattern.console=%clr(%d{yyyy-MM-dd HH:mm:ss.SSS}){faint} %clr(%5p) %clr($ threadId: {PID:- }){magenta} %clr(---){faint} %clr([ hostname: %X{hostname} serviceName: %X{serviceName} version: %X{version} transactionId: %X{transactionId} requestTimeStamp: %X{requestTimestamp} responseTimeStamp: %X{responseTimestamp} duration: %X{duration}]){yellow} %clr([%15.15t]){faint} %clr(%-40.40logger{39}){cyan} %clr(:){faint} %m%n%wex + +logging.level.org.springframework.web=INFO +logging.level.org.hibernate.SQL=warn +logging.level.org.hibernate.type.descriptor.sql=debug + +#To Remove Null in JSON API Response +spring.jackson.default-property-inclusion=non_null + +#Swagger Configuration +swagger.contact.name=Brinda Santh Muthuramalingam +swagger.contact.url=www.onap.com +swagger.contact.email=brindasanth@onap.com + +spring.jpa.properties.hibernate.show_sql=true +spring.jpa.properties.hibernate.use_sql_comments=true +spring.jpa.properties.hibernate.format_sql=true + +# spring.datasource.url, spring.datasource.username,spring.datasource.password may be overridden by ENV variables +spring.datasource.url=jdbc:mysql://localhost:3306/sdnctl +spring.datasource.username=sdnctl +spring.datasource.password=sdnctl +spring.datasource.driver-class-name=org.mariadb.jdbc.Driver +spring.jpa.show-sql=true +spring.jpa.hibernate.ddl-auto=none +spring.jpa.hibernate.naming-strategy=org.hibernate.cfg.ImprovedNamingStrategy +spring.jpa.properties.hibernate.dialect=org.hibernate.dialect.MySQL5InnoDBDialect +# Load Resource Source Mappings +resourceSourceMappings=db=source-db,input=source-input,default=source-default,mdsal=source-rest,capability=source-capability +# Controller Blueprints Core Configuration +controllerblueprints.blueprintDeployPath=/etc/blueprints/deploy +controllerblueprints.blueprintArchivePath=/etc/blueprints/archive +controllerblueprints.blueprintEnrichmentPath=/etc/blueprints/enrichment +# Controller Blueprint Load Configurations +controllerblueprints.loadInitialData=true +controllerblueprints.loadBluePrint=false +controllerblueprints.loadBluePrintPaths=./../../../components/model-catalog/blueprint-model/starter-blueprint +controllerblueprints.loadModelType=true +controllerblueprints.loadModeTypePaths=./../../../components/model-catalog/definition-type/starter-type +controllerblueprints.loadResourceDictionary=true +controllerblueprints.loadResourceDictionaryPaths=./../../../components/model-catalog/resource-dictionary/starter-dictionary + +# CBA file extension +controllerblueprints.loadCbaExtension=zip + +# Web server config +server.port=8080 \ No newline at end of file diff --git a/ms/controllerblueprints/application/src/main/resources/application.properties b/ms/controllerblueprints/application/src/main/resources/application.properties new file mode 100755 index 000000000..b6d509ce8 --- /dev/null +++ b/ms/controllerblueprints/application/src/main/resources/application.properties @@ -0,0 +1,74 @@ +# +# Copyright © 2017-2018 AT&T Intellectual Property. +# Modifications Copyright © 2019 Bell Canada. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +appName=ControllerBluePrints +ms_name=org.onap.ccsdk.apps.controllerblueprints +appVersion=1.0.0 + +# Basic Authentication +basic-auth.user-name=ccsdkapps +basic-auth.hashed-pwd={bcrypt}$2a$10$MJxhNiOAffxbyrV9.rrOUewP9Q/ASg5Nit2cmP.yBaXGsVXo8BW3y + +#logging.pattern.console=%clr(%d{yyyy-MM-dd HH:mm:ss.SSS}){faint} %clr(%5p) %clr($ threadId: {PID:- }){magenta} %clr(---){faint} %clr([ hostname: %X{hostname} serviceName: %X{serviceName} version: %X{version} transactionId: %X{transactionId} requestTimeStamp: %X{requestTimestamp} responseTimeStamp: %X{responseTimestamp} duration: %X{duration}]){yellow} %clr([%15.15t]){faint} %clr(%-40.40logger{39}){cyan} %clr(:){faint} %m%n%wex + +logging.level.org.springframework.web=INFO +logging.level.org.hibernate.SQL=warn +logging.level.org.hibernate.type.descriptor.sql=debug + +#To Remove Null in JSON API Response +spring.jackson.default-property-inclusion=non_null + +#Swagger Configuration +swagger.contact.name=Brinda Santh Muthuramalingam +swagger.contact.url=www.onap.com +swagger.contact.email=brindasanth@onap.com + +spring.jpa.properties.hibernate.show_sql=true +spring.jpa.properties.hibernate.use_sql_comments=true +spring.jpa.properties.hibernate.format_sql=true + +# spring.datasource.url, spring.datasource.username,spring.datasource.password may be overridden by ENV variables +spring.datasource.url=jdbc:mysql://db:3306/sdnctl +spring.datasource.username=sdnctl +spring.datasource.password=sdnctl +spring.datasource.driver-class-name=org.mariadb.jdbc.Driver +spring.jpa.show-sql=true +spring.jpa.hibernate.ddl-auto=none +spring.jpa.hibernate.naming-strategy=org.hibernate.cfg.ImprovedNamingStrategy +spring.jpa.properties.hibernate.dialect=org.hibernate.dialect.MySQL5InnoDBDialect + +# Load Resource Source Mappings +resourceSourceMappings=db=source-db,input=source-input,default=source-default,mdsal=source-rest,capability=source-capability + +# Controller Blueprints Core Configuration +controllerblueprints.blueprintDeployPath=/etc/blueprints/deploy +controllerblueprints.blueprintArchivePath=/etc/blueprints/archive +controllerblueprints.blueprintEnrichmentPath=/etc/blueprints/enrichment +# Controller Blueprint Load Configurations +# blueprints.load.initial-data may be overridden by ENV variables +controllerblueprints.loadInitialData=true +controllerblueprints.loadBluePrint=false +controllerblueprints.loadBluePrintPaths=/model-catalog/blueprint-model/starter-blueprint +controllerblueprints.loadModelType=true +controllerblueprints.loadModeTypePaths=/model-catalog/definition-type/starter-type +controllerblueprints.loadResourceDictionary=true +controllerblueprints.loadResourceDictionaryPaths=/model-catalog/resource-dictionary/starter-dictionary + +# CBA file extension +controllerblueprints.loadCbaExtension=zip + +# Web server config +server.port=8080 \ No newline at end of file diff --git a/ms/controllerblueprints/application/src/test/java/org/onap/ccsdk/apps/controllerblueprints/ControllerBlueprintsApplicationTest.java b/ms/controllerblueprints/application/src/test/java/org/onap/ccsdk/apps/controllerblueprints/ControllerBlueprintsApplicationTest.java new file mode 100644 index 000000000..cf9b3e71f --- /dev/null +++ b/ms/controllerblueprints/application/src/test/java/org/onap/ccsdk/apps/controllerblueprints/ControllerBlueprintsApplicationTest.java @@ -0,0 +1,62 @@ +/* + * Copyright © 2017-2018 AT&T Intellectual Property. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.onap.ccsdk.apps.controllerblueprints; + +import org.junit.Before; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.boot.test.context.SpringBootTest; +import org.springframework.boot.test.context.SpringBootTest.WebEnvironment; +import org.springframework.boot.test.web.client.TestRestTemplate; +import org.springframework.http.HttpHeaders; +import org.springframework.http.MediaType; +import org.springframework.http.client.support.BasicAuthorizationInterceptor; +import org.springframework.test.context.junit4.SpringRunner; + +@RunWith(SpringRunner.class) +@SpringBootTest(webEnvironment = WebEnvironment.RANDOM_PORT) +public class ControllerBlueprintsApplicationTest { + @Autowired + private TestRestTemplate restTemplate; + + @Before + public void setUp(){ + BasicAuthorizationInterceptor bai = new BasicAuthorizationInterceptor("ccsdkapps", "ccsdkapps"); + this.restTemplate.getRestTemplate().getInterceptors().add(bai); + } + + @Test + public void testConfigModel() { + HttpHeaders headers = new HttpHeaders(); + headers.set("Accept", MediaType.APPLICATION_JSON_VALUE); +// ResponseEntity entity = this.restTemplate +// .exchange("/api/v1/config-model/1", HttpMethod.GET, new HttpEntity<>(headers),BlueprintModel.class); +// assertThat(entity.getStatusCode()).isEqualTo(HttpStatus.OK); +// Assert.assertNotNull("failed to get response Config model",entity.getBody()); + } + + @Test + public void testConfigModelFailure() { + HttpHeaders headers = new HttpHeaders(); + headers.set("Accept", MediaType.APPLICATION_JSON_VALUE); +// ResponseEntity entity = this.restTemplate +// .exchange("/api/v1/config-model-not-found/1", HttpMethod.GET, new HttpEntity<>(headers),BlueprintModel.class); +// assertThat(entity.getStatusCode()).isEqualTo(HttpStatus.NOT_FOUND); +// Assert.assertNotNull("failed to get response Config model",entity.getBody()); + } +} diff --git a/ms/controllerblueprints/application/src/test/java/org/onap/ccsdk/apps/controllerblueprints/ControllerBluprintsApplicationTest.java b/ms/controllerblueprints/application/src/test/java/org/onap/ccsdk/apps/controllerblueprints/ControllerBluprintsApplicationTest.java deleted file mode 100644 index 969f80428..000000000 --- a/ms/controllerblueprints/application/src/test/java/org/onap/ccsdk/apps/controllerblueprints/ControllerBluprintsApplicationTest.java +++ /dev/null @@ -1,62 +0,0 @@ -/* - * Copyright © 2017-2018 AT&T Intellectual Property. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package org.onap.ccsdk.apps.controllerblueprints; - -import org.junit.Before; -import org.junit.Test; -import org.junit.runner.RunWith; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.boot.test.context.SpringBootTest; -import org.springframework.boot.test.context.SpringBootTest.WebEnvironment; -import org.springframework.boot.test.web.client.TestRestTemplate; -import org.springframework.http.HttpHeaders; -import org.springframework.http.MediaType; -import org.springframework.http.client.support.BasicAuthorizationInterceptor; -import org.springframework.test.context.junit4.SpringRunner; - -@RunWith(SpringRunner.class) -@SpringBootTest(webEnvironment = WebEnvironment.RANDOM_PORT) -public class ControllerBluprintsApplicationTest { - @Autowired - private TestRestTemplate restTemplate; - - @Before - public void setUp(){ - BasicAuthorizationInterceptor bai = new BasicAuthorizationInterceptor("ccsdkapps", "ccsdkapps"); - this.restTemplate.getRestTemplate().getInterceptors().add(bai); - } - - @Test - public void testConfigModel() { - HttpHeaders headers = new HttpHeaders(); - headers.set("Accept", MediaType.APPLICATION_JSON_VALUE); -// ResponseEntity entity = this.restTemplate -// .exchange("/api/v1/config-model/1", HttpMethod.GET, new HttpEntity<>(headers),BlueprintModel.class); -// assertThat(entity.getStatusCode()).isEqualTo(HttpStatus.OK); -// Assert.assertNotNull("failed to get response Config model",entity.getBody()); - } - - @Test - public void testConfigModelFailure() { - HttpHeaders headers = new HttpHeaders(); - headers.set("Accept", MediaType.APPLICATION_JSON_VALUE); -// ResponseEntity entity = this.restTemplate -// .exchange("/api/v1/config-model-not-found/1", HttpMethod.GET, new HttpEntity<>(headers),BlueprintModel.class); -// assertThat(entity.getStatusCode()).isEqualTo(HttpStatus.NOT_FOUND); -// Assert.assertNotNull("failed to get response Config model",entity.getBody()); - } -} diff --git a/ms/controllerblueprints/application/src/test/resources/application.properties b/ms/controllerblueprints/application/src/test/resources/application.properties index 13b2aa754..9aebd7936 100755 --- a/ms/controllerblueprints/application/src/test/resources/application.properties +++ b/ms/controllerblueprints/application/src/test/resources/application.properties @@ -52,4 +52,7 @@ controllerblueprints.loadResourceDictionaryPaths=./../../../../components/model- controllerblueprints.loadCbaExtension=zip # CBA examples for tests cases -controllerblueprints.loadBlueprintsExamplesPath=./../../../../components/model-catalog/blueprint-model/test-blueprints \ No newline at end of file +controllerblueprints.loadBlueprintsExamplesPath=./../../../../components/model-catalog/blueprint-model/test-blueprints + +# Web server config +server.port=8080 \ No newline at end of file diff --git a/ms/controllerblueprints/distribution/pom.xml b/ms/controllerblueprints/distribution/pom.xml old mode 100644 new mode 100755 index 305712936..91d4bbca0 --- a/ms/controllerblueprints/distribution/pom.xml +++ b/ms/controllerblueprints/distribution/pom.xml @@ -1,6 +1,7 @@ controllerblueprints onap/ccsdk-controllerblueprints - ${https_proxy} - deploy - true - + ${https_proxy} + deploy + true + @@ -120,20 +121,20 @@ - println project.properties['ccsdk.project.version']; - def versionArray; + println project.properties['ccsdk.project.version'] + def versionArray if (project.properties['ccsdk.project.version'] != null ) { - versionArray = project.properties['ccsdk.project.version'].split('\\.'); + versionArray = project.properties['ccsdk.project.version'].split('\\.') } if (project.properties['ccsdk.project.version'].endsWith("-SNAPSHOT")) { - project.properties['project.docker.latesttag.version']=versionArray[0] + '.' + versionArray[1] + "-STAGING-latest"; + project.properties['project.docker.latesttag.version']=versionArray[0] + '.' + versionArray[1] + "-STAGING-latest" } else { - project.properties['project.docker.latesttag.version']=versionArray[0]+'.' + versionArray[1]+"-STAGING-latest"; + project.properties['project.docker.latesttag.version']=versionArray[0]+'.' + versionArray[1]+"-STAGING-latest" } - println 'New Tag for docker:' + project.properties['project.docker.latesttag.version']; + println 'New Tag for docker:' + project.properties['project.docker.latesttag.version'] @@ -143,34 +144,34 @@ - - - docker - - - - io.fabric8 - docker-maven-plugin - 0.26.1 - false - - - - ${image.name} - - try - ${basedir}/target/docker-stage - - ${project.version} - ${project.version}-STAGING-${maven.build.timestamp} - ${project.docker.latesttag.version} - - - - - true - - + + + docker + + + + io.fabric8 + docker-maven-plugin + 0.26.1 + false + + + + ${image.name} + + try + ${basedir}/target/docker-stage + + ${project.version} + ${project.version}-STAGING-${maven.build.timestamp} + ${project.docker.latesttag.version} + + + + + true + + generate-images package @@ -186,11 +187,11 @@ push - - - - - + + + + + - + diff --git a/ms/controllerblueprints/distribution/src/main/dc/docker-compose.yaml b/ms/controllerblueprints/distribution/src/main/dc/docker-compose.yaml old mode 100644 new mode 100755 index eae24703b..232bfc016 --- a/ms/controllerblueprints/distribution/src/main/dc/docker-compose.yaml +++ b/ms/controllerblueprints/distribution/src/main/dc/docker-compose.yaml @@ -1,37 +1,33 @@ -version: '3.3' - -services: - db: - image: mariadb:latest - container_name: cb-mariadb - ports: - - "3306:3306" - volumes: - - ~/vm_mysql:/var/lib/mysql - restart: always - environment: - MYSQL_ROOT_PASSWORD: sdnctl - MYSQL_DATABASE: sdnctl - MYSQL_USER: sdnctl - MYSQL_PASSWORD: sdnctl - controller-blueprints: - depends_on: - - db - image: onap/ccsdk-controllerblueprints:latest - container_name: cb-rest - ports: - - "8080:8080" - restart: always - volumes: - - ~/share/vm_ms/controllerblueprints/config:/opt/app/onap/config - - ~/share/vm_ms/controllerblueprints/logs:/logs - environment: - APPLICATIONNAME : ControllerBluePrints - BUNDLEVERSION: 1.0.0 - APP_CONFIG_HOME: /opt/app/onap/config - DB_URL: jdbc:mysql://db:3306/sdnctl - DB_USER: sdnctl - DB_PASSWORD: sdnctl - INIT_DATA_LOAD: "true" - STICKYSELECTORKEY: - ENVCONTEXT: DEV \ No newline at end of file +version: '3.3' + +services: + db: + image: mariadb:latest + container_name: ccsdk-mariadb + ports: + - "3306:3306" + volumes: + - ~/vm_mysql:/var/lib/mysql + restart: always + environment: + MYSQL_ROOT_PASSWORD: sdnctl + MYSQL_DATABASE: sdnctl + MYSQL_USER: sdnctl + MYSQL_PASSWORD: sdnctl + controller-blueprints: + depends_on: + - db + image: onap/ccsdk-controllerblueprints:latest + container_name: cb-rest + ports: + - "8080:8080" + restart: always + volumes: + - ~/share/vm_ms/controllerblueprints/config:/opt/app/onap/config + - ~/share/vm_ms/controllerblueprints/logs:/logs + environment: + APPLICATIONNAME: ControllerBluePrints + BUNDLEVERSION: 1.0.0 + APP_CONFIG_HOME: /opt/app/onap/config + STICKYSELECTORKEY: + ENVCONTEXT: dev \ No newline at end of file diff --git a/ms/controllerblueprints/distribution/src/main/docker/Dockerfile b/ms/controllerblueprints/distribution/src/main/docker/Dockerfile old mode 100644 new mode 100755 index 6de589dac..88577f5af --- a/ms/controllerblueprints/distribution/src/main/docker/Dockerfile +++ b/ms/controllerblueprints/distribution/src/main/docker/Dockerfile @@ -15,6 +15,7 @@ RUN (mkdir -p /source /opt/app/onap) && (tar -xzf /source.tar.gz -C /source) \ && (cp -rf /source/app/opt/app/onap/lib /opt/app/onap/) \ && (cp -rf /source/app/etc /) \ && (cp -rf /source/app/model-catalog /) \ +&& (cp -rf /source/app/config /) \ && (rm -rf /source) -ENTRYPOINT /startService.sh +ENTRYPOINT /startService.sh \ No newline at end of file diff --git a/ms/controllerblueprints/distribution/src/main/docker/distribution.xml b/ms/controllerblueprints/distribution/src/main/docker/distribution.xml old mode 100644 new mode 100755 index c929f98ef..1555b43e7 --- a/ms/controllerblueprints/distribution/src/main/docker/distribution.xml +++ b/ms/controllerblueprints/distribution/src/main/docker/distribution.xml @@ -1,6 +1,7 @@