|
158 | 158 | <artifactId>spring-boot-maven-plugin</artifactId>
|
159 | 159 | </plugin>
|
160 | 160 | <plugin>
|
161 |
| - <groupId>com.spotify</groupId> |
162 |
| - <artifactId>dockerfile-maven-plugin</artifactId> |
163 |
| - <version>1.4.13</version> |
| 161 | + <groupId>org.codehaus.mojo</groupId> |
| 162 | + <artifactId>exec-maven-plugin</artifactId> |
| 163 | + <version>3.3.0</version> |
164 | 164 | <executions>
|
165 | 165 | <execution>
|
166 |
| - <id>default</id> |
| 166 | + <id>docker-build</id> |
| 167 | + <phase>package</phase> |
167 | 168 | <goals>
|
168 |
| - <goal>build</goal> |
| 169 | + <goal>exec</goal> |
169 | 170 | </goals>
|
| 171 | + <configuration> |
| 172 | + <executable>docker</executable> |
| 173 | + <workingDirectory>${project.basedir}</workingDirectory> |
| 174 | + <arguments> |
| 175 | + <argument>build</argument> |
| 176 | + <argument>-f</argument> |
| 177 | + <argument>Dockerfile</argument> |
| 178 | + <argument>--build-arg</argument> |
| 179 | + <argument>JAR_FILE=${project.artifactId}-${project.version}.jar</argument> |
| 180 | + <argument>-t</argument> |
| 181 | + <argument>protegeproject/${project.artifactId}:${project.version}</argument> |
| 182 | + <argument>.</argument> |
| 183 | + </arguments> |
| 184 | + </configuration> |
| 185 | + </execution> |
| 186 | + <execution> |
| 187 | + <id>docker-push</id> |
| 188 | + <phase>install</phase> |
| 189 | + <goals> |
| 190 | + <goal>exec</goal> |
| 191 | + </goals> |
| 192 | + <configuration> |
| 193 | + <executable>docker</executable> |
| 194 | + <workingDirectory>${project.basedir}</workingDirectory> |
| 195 | + <arguments> |
| 196 | + <argument>push</argument> |
| 197 | + <argument>protegeproject/${project.artifactId}:${project.version}</argument> |
| 198 | + </arguments> |
| 199 | + </configuration> |
170 | 200 | </execution>
|
171 | 201 | </executions>
|
172 |
| - <configuration> |
173 |
| - <repository>protegeproject/${project.artifactId}</repository> |
174 |
| - <tag>${project.version}</tag> |
175 |
| - <buildArgs> |
176 |
| - <JAR_FILE>${project.build.finalName}.jar</JAR_FILE> |
177 |
| - </buildArgs> |
178 |
| -<!-- <username>${env.DOCKER_USERNAME}</username>--> |
179 |
| -<!-- <password>${env.DOCKER_PASSWORD}</password>--> |
180 |
| - </configuration> |
181 | 202 | </plugin>
|
182 | 203 | </plugins>
|
183 | 204 | </build>
|
184 | 205 |
|
185 |
| - <profiles> |
186 |
| - <profile> |
187 |
| - <id>release</id> |
188 |
| - <build> |
189 |
| - <plugins> |
190 |
| - <plugin> |
191 |
| - <groupId>org.apache.maven.plugins</groupId> |
192 |
| - <artifactId>maven-source-plugin</artifactId> |
193 |
| - <version>3.2.1</version> |
194 |
| - <executions> |
195 |
| - <execution> |
196 |
| - <id>attach-sources</id> |
197 |
| - <goals> |
198 |
| - <goal>jar-no-fork</goal> |
199 |
| - </goals> |
200 |
| - </execution> |
201 |
| - </executions> |
202 |
| - </plugin> |
203 |
| - |
204 |
| - <plugin> |
205 |
| - <groupId>org.apache.maven.plugins</groupId> |
206 |
| - <artifactId>maven-javadoc-plugin</artifactId> |
207 |
| - <version>3.2.0</version> |
208 |
| - <configuration> |
209 |
| - <doclint>none</doclint> |
210 |
| - <release>16</release> |
211 |
| - </configuration> |
212 |
| - <executions> |
213 |
| - <execution> |
214 |
| - <id>attach-javadocs</id> |
215 |
| - <goals> |
216 |
| - <goal>jar</goal> |
217 |
| - </goals> |
218 |
| - </execution> |
219 |
| - </executions> |
220 |
| - </plugin> |
221 |
| - |
222 |
| - <plugin> |
223 |
| - <groupId>org.apache.maven.plugins</groupId> |
224 |
| - <artifactId>maven-gpg-plugin</artifactId> |
225 |
| - <version>1.6</version> |
226 |
| - <executions> |
227 |
| - <execution> |
228 |
| - <id>sign-artifacts</id> |
229 |
| - <phase>verify</phase> |
230 |
| - <goals> |
231 |
| - <goal>sign</goal> |
232 |
| - </goals> |
233 |
| - <configuration> |
234 |
| - <gpgArguments> |
235 |
| - <arg>--pinentry-mode</arg> |
236 |
| - <arg>loopback</arg> |
237 |
| - </gpgArguments> |
238 |
| - </configuration> |
239 |
| - </execution> |
240 |
| - </executions> |
241 |
| - </plugin> |
242 |
| - |
243 |
| - <plugin> |
244 |
| - <groupId>org.sonatype.plugins</groupId> |
245 |
| - <artifactId>nexus-staging-maven-plugin</artifactId> |
246 |
| - <version>1.6.7</version> |
247 |
| - <extensions>true</extensions> |
248 |
| - <configuration> |
249 |
| - <serverId>ossrh</serverId> |
250 |
| - <nexusUrl>https://oss.sonatype.org</nexusUrl> |
251 |
| - <autoReleaseAfterClose>true</autoReleaseAfterClose> |
252 |
| - </configuration> |
253 |
| - <dependencies> |
254 |
| - <!-- |
255 |
| - TODO: |
256 |
| - Remove after OSSRH-66257, NEXUS-26993 are fixed, |
257 |
| - possibly via https://github.com/sonatype/nexus-maven-plugins/pull/91 |
258 |
| - --> |
259 |
| - <dependency> |
260 |
| - <groupId>com.thoughtworks.xstream</groupId> |
261 |
| - <artifactId>xstream</artifactId> |
262 |
| - <version>1.4.15</version> |
263 |
| - </dependency> |
264 |
| - </dependencies> |
265 |
| - </plugin> |
266 |
| - |
267 |
| - </plugins> |
268 |
| - </build> |
269 |
| - </profile> |
270 |
| - <profile> |
271 |
| - <id>local</id> |
272 |
| - <properties> |
273 |
| - <spring.profiles.active>local</spring.profiles.active> |
274 |
| - </properties> |
275 |
| - </profile> |
276 |
| - </profiles> |
277 |
| - |
278 | 206 | </project>
|
0 commit comments