Move karaf scripts in its own artifact 86/80586/4
authorAlexis de Talhouët <adetalhouet89@gmail.com>
Mon, 25 Feb 2019 14:32:58 +0000 (09:32 -0500)
committerAlexis de Talhouët <adetalhouet89@gmail.com>
Mon, 25 Feb 2019 22:24:02 +0000 (22:24 +0000)
In order to have downstream consumer able to build an ODL
distribution without the need to fork these scripts, these
should be held within an artifact from which we can simply
copy them.

Change-Id: I8b263805cbc5c2736ae3843ccf10a7aac5183580
Signed-off-by: Alexis de Talhouët <adetalhouet89@gmail.com>
karaf-scripts/pom.xml [new file with mode: 0644]
karaf-scripts/src/main/assembly/bin/configure-cluster-ipdetect.sh [moved from karaf/src/main/assembly/bin/configure-cluster-ipdetect.sh with 100% similarity]
karaf-scripts/src/main/assembly/bin/configure_cluster.sh [moved from karaf/src/main/assembly/bin/configure_cluster.sh with 100% similarity]
karaf-scripts/src/main/assembly/bin/custom_shard_config.txt [moved from karaf/src/main/assembly/bin/custom_shard_config.txt with 100% similarity]
karaf-scripts/src/main/assembly/bin/set_persistence.sh [moved from karaf/src/main/assembly/bin/set_persistence.sh with 100% similarity]
karaf-scripts/src/main/assembly/etc/org.ops4j.pax.url.mvn.cfg [moved from karaf/src/main/assembly/etc/org.ops4j.pax.url.mvn.cfg with 100% similarity]
karaf-scripts/src/main/assembly/etc/shell.init.script [moved from karaf/src/main/assembly/etc/shell.init.script with 100% similarity]
karaf/pom.xml
pom.xml

diff --git a/karaf-scripts/pom.xml b/karaf-scripts/pom.xml
new file mode 100644 (file)
index 0000000..a8e8e38
--- /dev/null
@@ -0,0 +1,34 @@
+<?xml version="1.0"?>
+<!--
+ Copyright (c) 2019 Bell Canada and others. All rights reserved.
+
+ This program and the accompanying materials are made available under the
+ terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ and is available at http://www.eclipse.org/legal/epl-v10.html
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+    <modelVersion>4.0.0</modelVersion>
+    <parent>
+        <groupId>org.opendaylight.odlparent</groupId>
+        <artifactId>odlparent-lite</artifactId>
+        <version>4.0.9</version>
+        <relativePath/>
+    </parent>
+    <groupId>org.opendaylight.integration</groupId>
+    <artifactId>karaf-scripts</artifactId>
+    <version>0.11.0-SNAPSHOT</version>
+    <packaging>jar</packaging>
+    <name>ODL :: integration :: Karaf :: Scripts :: ${project.artifactId}</name>
+    <description>The actual Karaf archive building sub-project.</description>
+
+    <build>
+        <resources>
+            <resource>
+                <directory>src/main/assembly</directory>
+                <filtering>false</filtering>
+            </resource>
+        </resources>
+    </build>
+
+</project>
index cec62914d080517868dd33323c1f6bb8119d1e1f..bf866f8d497178f2d2154f5af142e5e679d5c776 100644 (file)
@@ -7,7 +7,8 @@
  terms of the Eclipse Public License v1.0 which accompanies this distribution,
  and is available at http://www.eclipse.org/legal/epl-v10.html
 -->
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
     <modelVersion>4.0.0</modelVersion>
     <parent>
         <groupId>org.opendaylight.odlparent</groupId>
             </exclusions>
         </dependency>
 
+        <!-- This scope test here is just a trick, so that we can use the dependencies
+         in maven-dependency-plugin, but don't have karaf-maven-plugin choke on it -->
         <dependency>
             <groupId>org.opendaylight.aaa</groupId>
             <artifactId>aaa-cli-jar</artifactId>
-            <!-- This scope test here is just a trick, so that we can use aaa-cli-jar in maven-dependency-plugin, but don't have karaf-maven-plugin choke on it -->
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.opendaylight.integration</groupId>
+            <artifactId>karaf-scripts</artifactId>
+            <version>${project.version}</version>
             <scope>test</scope>
         </dependency>
     </dependencies>
                             <stripVersion>true</stripVersion>
                         </configuration>
                     </execution>
+                    <execution>
+                        <id>unpack-odl-karaf-resources</id>
+                        <goals>
+                            <goal>unpack-dependencies</goal>
+                        </goals>
+                        <phase>prepare-package</phase>
+                        <configuration>
+                            <outputDirectory>${project.build.directory}/assembly</outputDirectory>
+                            <groupId>org.opendaylight.integration</groupId>
+                            <includeArtifactIds>karaf-scripts</includeArtifactIds>
+                            <excludes>META-INF\/**</excludes>
+                            <excludeTransitive>true</excludeTransitive>
+                            <ignorePermissions>false</ignorePermissions>
+                        </configuration>
+                    </execution>
                 </executions>
             </plugin>
         </plugins>
diff --git a/pom.xml b/pom.xml
index e8077097c7cf0ae4e317c674fc5587ab17003c8f..3f975072c15388895804beaa7e1c16eda0123c30 100644 (file)
--- a/pom.xml
+++ b/pom.xml
@@ -44,6 +44,7 @@
             </activation>
             <modules>
                 <module>artifacts</module>
+                <module>karaf-scripts</module>
                 <module>karaf</module>
                 <module>features</module>
             </modules>