Merge "Prepare for release build"
[ccsdk/sli/adaptors.git] / saltstack-adapter / saltstack-adapter-installer / pom.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!--
3   ============LICENSE_START=======================================================
4   ONAP : CCSDK
5   ================================================================================
6   Copyright (C) 2018 Samsung Electronics. All rights reserved.
7   ================================================================================
8
9   =============================================================================
10   Licensed under the Apache License, Version 2.0 (the "License");
11   you may not use this file except in compliance with the License.
12   You may obtain a copy of the License at
13
14        http://www.apache.org/licenses/LICENSE-2.0
15
16   Unless required by applicable law or agreed to in writing, software
17   distributed under the License is distributed on an "AS IS" BASIS,
18   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
19   See the License for the specific language governing permissions and
20   limitations under the License.
21
22
23   ============LICENSE_END=========================================================
24   -->
25 <project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://maven.apache.org/POM/4.0.0" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
26     <modelVersion>4.0.0</modelVersion>
27     <parent>
28         <groupId>org.onap.ccsdk.parent</groupId>
29         <artifactId>odlparent-lite</artifactId>
30         <version>1.2.0</version>
31         <relativePath/>
32     </parent>
33     <groupId>org.onap.ccsdk.sli.adaptors</groupId>
34     <artifactId>saltstack-adapter-installer</artifactId>
35     <version>0.4.0-SNAPSHOT</version>
36     <name>ccsdk-sli-adaptors :: saltstack-adapter :: ${project.artifactId}
37     </name>
38     <packaging>pom</packaging>
39     <properties>
40         <application.name>ccsdk-saltstack-adapter</application.name>
41         <features.boot>${application.name}</features.boot>
42         <features.repositories>
43             mvn:org.onap.ccsdk.sli.adaptors/${features.boot}/${project.version}/xml/features
44         </features.repositories>
45         <include.transitive.dependencies>false</include.transitive.dependencies>
46     </properties>
47     <dependencies>
48         <dependency>
49             <groupId>org.onap.ccsdk.sli.adaptors</groupId>
50             <artifactId>${application.name}</artifactId>
51             <version>${project.version}</version>
52             <classifier>features</classifier>
53             <type>xml</type>
54             <exclusions>
55                 <exclusion>
56                     <groupId>*</groupId>
57                     <artifactId>*</artifactId>
58                 </exclusion>
59             </exclusions>
60         </dependency>
61         <dependency>
62             <groupId>org.onap.ccsdk.sli.adaptors</groupId>
63             <artifactId>saltstack-adapter-provider</artifactId>
64             <version>${project.version}</version>
65         </dependency>
66
67         <dependency>
68             <groupId>javax</groupId>
69             <artifactId>javaee-api</artifactId>
70             <version>7.0</version>
71         </dependency>
72     </dependencies>
73     <build>
74         <plugins>
75             <plugin>
76                 <artifactId>maven-assembly-plugin</artifactId>
77                 <executions>
78                     <execution>
79                         <id>maven-repo-zip</id>
80                         <goals>
81                             <goal>single</goal>
82                         </goals>
83                         <phase>package</phase>
84                         <configuration>
85                             <appendAssemblyId>true</appendAssemblyId>
86                             <attach>false</attach>
87                             <finalName>
88                                 stage/${application.name}-${project.version}
89                             </finalName>
90                             <descriptors>
91                                 <descriptor>
92                                     src/assembly/assemble_mvnrepo_zip.xml
93                                 </descriptor>
94                             </descriptors>
95                         </configuration>
96                     </execution>
97                     <execution>
98                         <id>installer-zip</id>
99                         <goals>
100                             <goal>single</goal>
101                         </goals>
102                         <phase>package</phase>
103                         <configuration>
104                             <appendAssemblyId>false</appendAssemblyId>
105                             <attach>true</attach>
106                             <finalName>${application.name}-${project.version}
107                             </finalName>
108                             <descriptors>
109                                 <descriptor>
110                                     src/assembly/assemble_installer_zip.xml
111                                 </descriptor>
112                             </descriptors>
113                         </configuration>
114                     </execution>
115                 </executions>
116             </plugin>
117             <plugin>
118                 <groupId>org.apache.maven.plugins</groupId>
119                 <artifactId>maven-dependency-plugin</artifactId>
120                 <executions>
121                     <execution>
122                         <id>copy-dependencies</id>
123                         <goals>
124                             <goal>copy-dependencies</goal>
125                         </goals>
126                         <phase>prepare-package</phase>
127                         <configuration>
128                             <transitive>false</transitive>
129                             <outputDirectory>
130                                 ${project.build.directory}/assembly/system
131                             </outputDirectory>
132                             <overWriteReleases>false</overWriteReleases>
133                             <overWriteSnapshots>true</overWriteSnapshots>
134                             <overWriteIfNewer>true</overWriteIfNewer>
135                             <useRepositoryLayout>true</useRepositoryLayout>
136                             <addParentPoms>false</addParentPoms>
137                             <copyPom>false</copyPom>
138                             <excludeGroupIds>org.opendaylight</excludeGroupIds>
139                             <scope>provided</scope>
140                         </configuration>
141                     </execution>
142                 </executions>
143             </plugin>
144             <plugin>
145                 <artifactId>maven-resources-plugin</artifactId>
146                 <executions>
147                     <execution>
148                         <id>copy-version</id>
149                         <goals>
150                             <goal>copy-resources</goal>
151                         </goals>
152                         <!-- here the phase you need -->
153                         <phase>validate</phase>
154                         <configuration>
155                             <outputDirectory>${basedir}/target/stage
156                             </outputDirectory>
157                             <resources>
158                                 <resource>
159                                     <directory>src/main/resources/scripts
160                                     </directory>
161                                     <includes>
162                                         <include>install-feature.sh</include>
163                                     </includes>
164                                     <filtering>true</filtering>
165                                 </resource>
166                             </resources>
167                         </configuration>
168                     </execution>
169                 </executions>
170             </plugin>
171         </plugins>
172     </build>
173 </project>