From: Timoney, Dan (dt5972) Date: Fri, 22 Jun 2018 19:53:19 +0000 (-0400) Subject: Add feature aggregator X-Git-Tag: 0.3.0~28^2 X-Git-Url: https://gerrit.onap.org/r/gitweb?a=commitdiff_plain;h=e8670e23820ae4d648b88c050b46add498303a9f;p=ccsdk%2Fsli%2Fplugins.git Add feature aggregator Added feature aggregator ccsdk-sli-plugins-all so that all features from sli/plugins repo can be added with one install. Change-Id: I85ff00612ee60e69937c7b10d814cf81198ed51c Issue-ID: CCSDK-283 Signed-off-by: Timoney, Dan (dt5972) --- diff --git a/features/ccsdk-sli-plugins-all/pom.xml b/features/ccsdk-sli-plugins-all/pom.xml new file mode 100644 index 00000000..756e7590 --- /dev/null +++ b/features/ccsdk-sli-plugins-all/pom.xml @@ -0,0 +1,58 @@ + + + 4.0.0 + + + org.onap.ccsdk.parent + single-feature-parent + 1.1.0-SNAPSHOT + + + + org.onap.ccsdk.sli.plugins + ccsdk-sli-plugins-all + 0.3.0-SNAPSHOT + feature + + ccsdk-sli-plugins :: features :: ${project.artifactId} + + + + org.opendaylight.mdsal.model + mdsal-model-artifacts + ${odl.mdsal.model.version} + pom + import + + + org.opendaylight.controller + mdsal-artifacts + ${odl.mdsal.version} + pom + import + + + + + + + ${project.groupId} + ccsdk-properties-node + ${project.version} + xml + features + + + ${project.groupId} + ccsdk-restapi-call-node + ${project.version} + xml + features + + + + + + diff --git a/features/features-sli-plugins/pom.xml b/features/features-sli-plugins/pom.xml new file mode 100644 index 00000000..0b43d1a0 --- /dev/null +++ b/features/features-sli-plugins/pom.xml @@ -0,0 +1,29 @@ + + + 4.0.0 + + + org.onap.ccsdk.parent + feature-repo-parent + 1.1.0-SNAPSHOT + + + + org.onap.ccsdk.sli.plugins + features-sli-plugins + 0.3.0-SNAPSHOT + feature + + ccsdk-sli-plugins :: features :: ${project.artifactId} + + + + ${project.groupId} + ccsdk-sli-plugins-all + ${project.version} + xml + features + + + + diff --git a/features/installer/pom.xml b/features/installer/pom.xml new file mode 100755 index 00000000..050d3e9d --- /dev/null +++ b/features/installer/pom.xml @@ -0,0 +1,137 @@ + + + 4.0.0 + + + org.onap.ccsdk.parent + odlparent-lite + 1.1.0-SNAPSHOT + + + + org.onap.ccsdk.sli.plugins + sliplugins-features-installer + 0.3.0-SNAPSHOT + pom + + ccsdk-sli-plugins :: features :: ${project.artifactId} + + + ccsdk-sli-plugins-all + ${application.name} + mvn:org.onap.ccsdk.sli.plugins/${features.boot}/${project.version}/xml/features + false + + + + + + org.onap.ccsdk.sli.plugins + ${application.name} + ${project.version} + xml + features + + + * + * + + + + + + + + + + + maven-assembly-plugin + + + maven-repo-zip + + single + + package + + true + stage/${application.name}-${project.version} + + src/assembly/assemble_mvnrepo_zip.xml + + true + + + + installer-zip + + single + + package + + true + ${application.name}-${project.version}-installer + + src/assembly/assemble_installer_zip.xml + + false + + + + + + org.apache.maven.plugins + maven-dependency-plugin + + + copy-dependencies + + copy-dependencies + + prepare-package + + false + ${project.build.directory}/assembly/system + false + true + true + true + false + false + org.onap.ccsdk.sli.plugins + provided + + + + + + maven-resources-plugin + 2.6 + + + copy-version + + copy-resources + + validate + + ${basedir}/target/stage + + + src/main/resources/scripts + + install-feature.sh + + true + + + + + + + + + + + diff --git a/features/installer/src/assembly/assemble_installer_zip.xml b/features/installer/src/assembly/assemble_installer_zip.xml new file mode 100755 index 00000000..a6a22a9b --- /dev/null +++ b/features/installer/src/assembly/assemble_installer_zip.xml @@ -0,0 +1,39 @@ + + + + bin + + + zip + + + + false + + + + target/stage/ + ${application.name} + 755 + + *.sh + + + + target/stage/ + ${application.name} + 644 + + *.sh + + + + + + + diff --git a/features/installer/src/assembly/assemble_mvnrepo_zip.xml b/features/installer/src/assembly/assemble_mvnrepo_zip.xml new file mode 100755 index 00000000..86b07f1f --- /dev/null +++ b/features/installer/src/assembly/assemble_mvnrepo_zip.xml @@ -0,0 +1,29 @@ + + + + repo + + + zip + + + + false + + + + target/assembly/ + . + + + + + + + + diff --git a/features/installer/src/main/resources/scripts/install-feature.sh b/features/installer/src/main/resources/scripts/install-feature.sh new file mode 100644 index 00000000..e16e79a1 --- /dev/null +++ b/features/installer/src/main/resources/scripts/install-feature.sh @@ -0,0 +1,18 @@ +#!/bin/bash + +ODL_HOME=${ODL_HOME:-/opt/opendaylight/current} +ODL_KARAF_CLIENT=${ODL_KARAF_CLIENT:-${ODL_HOME}/bin/client} +INSTALLERDIR=$(dirname $0) + +REPOZIP=${INSTALLERDIR}/${features.boot}-${project.version}.zip + +if [ -f ${REPOZIP} ] +then + unzip -d ${ODL_HOME} ${REPOZIP} +else + echo "ERROR : repo zip ($REPOZIP) not found" + exit 1 +fi + +${ODL_KARAF_CLIENT} feature:repo-add ${features.repositories} +${ODL_KARAF_CLIENT} feature:install ${features.boot} diff --git a/features/pom.xml b/features/pom.xml new file mode 100755 index 00000000..3ac87bf6 --- /dev/null +++ b/features/pom.xml @@ -0,0 +1,24 @@ + + + 4.0.0 + + + org.onap.ccsdk.parent + odlparent-lite + 1.1.0-SNAPSHOT + + + + org.onap.ccsdk.sli.plugins + sliplugins-feature-aggregator + 0.3.0-SNAPSHOT + pom + + ccsdk-sli-plugins :: features + + + ccsdk-sli-plugins-all + features-sli-plugins + installer + + diff --git a/pom.xml b/pom.xml index 8c130133..b6efa94c 100755 --- a/pom.xml +++ b/pom.xml @@ -23,6 +23,7 @@ properties-node restapi-call-node + features diff --git a/properties-node/installer/pom.xml b/properties-node/installer/pom.xml index c9a11c61..965bdbb7 100755 --- a/properties-node/installer/pom.xml +++ b/properties-node/installer/pom.xml @@ -59,12 +59,12 @@ package - false + true stage/${application.name}-${project.version} src/assembly/assemble_mvnrepo_zip.xml - false + true diff --git a/properties-node/installer/src/assembly/assemble_mvnrepo_zip.xml b/properties-node/installer/src/assembly/assemble_mvnrepo_zip.xml index 2ee22447..9cdc7887 100644 --- a/properties-node/installer/src/assembly/assemble_mvnrepo_zip.xml +++ b/properties-node/installer/src/assembly/assemble_mvnrepo_zip.xml @@ -25,7 +25,7 @@ xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0 http://maven.apache.org/xsd/assembly-1.1.0.xsd"> - mvnrepo_zip + repo zip diff --git a/restapi-call-node/installer/pom.xml b/restapi-call-node/installer/pom.xml index 0badf58b..8e2f402e 100755 --- a/restapi-call-node/installer/pom.xml +++ b/restapi-call-node/installer/pom.xml @@ -66,12 +66,12 @@ package - false + true stage/${application.name}-${project.version} src/assembly/assemble_mvnrepo_zip.xml - false + true diff --git a/restapi-call-node/installer/src/assembly/assemble_mvnrepo_zip.xml b/restapi-call-node/installer/src/assembly/assemble_mvnrepo_zip.xml index cb56f2cd..35e79db1 100644 --- a/restapi-call-node/installer/src/assembly/assemble_mvnrepo_zip.xml +++ b/restapi-call-node/installer/src/assembly/assemble_mvnrepo_zip.xml @@ -25,7 +25,7 @@ xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0 http://maven.apache.org/xsd/assembly-1.1.0.xsd"> - mvnrepo_zip + repo zip