blob: 662864cb6ef27f89645673293a1c2927b8da7bb3 [file] [log] [blame]
Timoney, Dan (dt5972)12622052018-09-12 10:53:10 -04001<?xml version="1.0" encoding="UTF-8"?>
Timoney, Dan (dt5972)268c4ba2019-02-12 14:35:10 -05002<project xmlns="http://maven.apache.org/POM/4.0.0"
3 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4 xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
Timoney, Dan (dt5972)12622052018-09-12 10:53:10 -04005
Timoney, Dan (dt5972)268c4ba2019-02-12 14:35:10 -05006 <parent>
7 <groupId>org.onap.ccsdk.parent</groupId>
8 <artifactId>odlparent-lite</artifactId>
9 <version>1.2.1-SNAPSHOT</version>
10 </parent>
Sylvain Desbureaux1bc56902019-01-30 14:36:14 +010011
Timoney, Dan (dt5972)268c4ba2019-02-12 14:35:10 -050012 <modelVersion>4.0.0</modelVersion>
13 <packaging>pom</packaging>
14 <groupId>org.onap.ccsdk.distribution</groupId>
15 <artifactId>ansible-server</artifactId>
16 <version>0.4.1-SNAPSHOT</version>
Timoney, Dan (dt5972)12622052018-09-12 10:53:10 -040017
Timoney, Dan (dt5972)268c4ba2019-02-12 14:35:10 -050018 <name>ccsdk :: distribution :: ${project.artifactId}</name>
19 <description>Creates ansible-server Docker container</description>
Timoney, Dan (dt5972)12622052018-09-12 10:53:10 -040020
Timoney, Dan (dt5972)268c4ba2019-02-12 14:35:10 -050021 <properties>
22 <image.name>onap/ccsdk-ansible-server-image</image.name>
23 <ccsdk.project.version>${project.version}</ccsdk.project.version>
24 <ccsdk.build.timestamp>${maven.build.timestamp}</ccsdk.build.timestamp>
25 <ccsdk.distribution.version>${project.version}</ccsdk.distribution.version>
26 <maven.build.timestamp.format>yyyyMMdd'T'HHmmss'Z'</maven.build.timestamp.format>
27 <docker.verbose>true</docker.verbose>
28 </properties>
Timoney, Dan (dt5972)12622052018-09-12 10:53:10 -040029
30
Timoney, Dan (dt5972)268c4ba2019-02-12 14:35:10 -050031 <build>
32 <plugins>
33 <plugin>
34 <groupId>org.codehaus.groovy.maven</groupId>
35 <artifactId>gmaven-plugin</artifactId>
36 <executions>
37 <execution>
38 <phase>validate</phase>
39 <goals>
40 <goal>execute</goal>
41 </goals>
42 <configuration>
43 <source>${basedir}/../src/main/scripts/TagVersion.groovy</source>
44 </configuration>
45 </execution>
46 </executions>
47 </plugin>
Timoney, Dan (dt5972)12622052018-09-12 10:53:10 -040048
Timoney, Dan (dt5972)268c4ba2019-02-12 14:35:10 -050049 <plugin>
50 <artifactId>maven-resources-plugin</artifactId>
51 <version>2.6</version>
52 <executions>
53 <execution>
54 <id>copy-dockerfile</id>
55 <goals>
56 <goal>copy-resources</goal>
57 </goals><!-- here the phase you need -->
58 <phase>validate</phase>
59 <configuration>
60 <outputDirectory>${basedir}/target/docker-stage</outputDirectory>
61 <resources>
62 <resource>
63 <directory>src/main</directory>
64 <includes>
65 <include>**/*</include>
66 </includes>
67 <filtering>false</filtering>
68 </resource>
69 </resources>
70 </configuration>
71 </execution>
72 </executions>
73 </plugin>
Timoney, Dan (dt5972)12622052018-09-12 10:53:10 -040074
Timoney, Dan (dt5972)268c4ba2019-02-12 14:35:10 -050075 <plugin>
76 <artifactId>exec-maven-plugin</artifactId>
77 <groupId>org.codehaus.mojo</groupId>
78 <version>1.5.0</version>
79 <executions>
80 <execution>
81 <id>change python permissions</id>
82 <phase>process-sources</phase>
83 <goals>
84 <goal>exec</goal>
85 </goals>
86 <configuration>
87 <executable>/usr/bin/find</executable>
88 <arguments>
89 <argument>${basedir}/target/docker-stage/ansible-server</argument>
90 <argument>-name</argument>
91 <argument>*.py</argument>
92 <argument>-exec</argument>
93 <argument>chmod</argument>
94 <argument>+x</argument>
95 <argument>{}</argument>
96 <argument>;</argument>
97 </arguments>
98 </configuration>
99 </execution>
100 </executions>
101 </plugin>
102 </plugins>
103 </build>
Timoney, Dan (dt5972)12622052018-09-12 10:53:10 -0400104
Timoney, Dan (dt5972)268c4ba2019-02-12 14:35:10 -0500105 <profiles>
106 <profile>
107 <id>docker</id>
108 <build>
109 <plugins>
110 <plugin>
111 <groupId>io.fabric8</groupId>
112 <artifactId>docker-maven-plugin</artifactId>
113 <version>0.16.5</version>
114 <inherited>false</inherited>
115 <configuration>
116 <images>
117 <image>
118 <name>${image.name}</name>
119 <build>
120 <cleanup>try</cleanup>
121 <dockerFileDir>${basedir}/target/docker-stage</dockerFileDir>
122 <dockerFile>${basedir}/target/docker-stage/Dockerfile</dockerFile>
123 <tags>
124 <tag>${project.docker.latestminortag.version}</tag>
125 <tag>${project.docker.latestfulltag.version}</tag>
126 <tag>${project.docker.latesttagtimestamp.version}</tag>
127 </tags>
128 </build>
129 </image>
130 </images>
131 </configuration>
132 <executions>
133 <execution>
134 <id>generate-images</id>
135 <phase>package</phase>
136 <goals>
137 <goal>build</goal>
138 </goals>
139 </execution>
Timoney, Dan (dt5972)12622052018-09-12 10:53:10 -0400140
Timoney, Dan (dt5972)268c4ba2019-02-12 14:35:10 -0500141 <execution>
142 <id>push-images</id>
143 <phase>deploy</phase>
144 <goals>
145 <goal>build</goal>
146 <goal>push</goal>
147 </goals>
148 </execution>
149 </executions>
150 </plugin>
151 </plugins>
152 </build>
153 </profile>
154 </profiles>
155 <organization>
156 <name>ONAP</name>
157 </organization>
Timoney, Dan (dt5972)12622052018-09-12 10:53:10 -0400158</project>