Skip to content

Commit

Permalink
Migrate maven deploy to artifactory-push CLI (#1491)
Browse files Browse the repository at this point in the history
* migrate to artifactory-push

* move plugins outside of pluginManagement

* cleanup

* remove settings.xml

* add comments

---------

Co-authored-by: Jessica Chen <[email protected]>
  • Loading branch information
jjchen56 and Jessica Chen authored Mar 4, 2024
1 parent c7407c7 commit fbb862b
Show file tree
Hide file tree
Showing 3 changed files with 43 additions and 29 deletions.
13 changes: 0 additions & 13 deletions deploy-service/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -106,19 +106,6 @@
</plugins>
</build>

<distributionManagement>
<repository>
<id>central</id>
<name>maven-releases</name>
<url>https://artifacts-prod-use1.pinadmin.com/artifactory/maven-private-prod-sox-local</url>
</repository>
<snapshotRepository>
<id>snapshots</id>
<name>maven-snapshots</name>
<url>https://artifacts-prod-use1.pinadmin.com/artifactory/maven-private-prod-sox-local</url>
</snapshotRepository>
</distributionManagement>

<profiles>
<profile>
<id>coverage</id>
Expand Down
16 changes: 0 additions & 16 deletions deploy-service/settings.xml

This file was deleted.

43 changes: 43 additions & 0 deletions deploy-service/universal/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,9 @@
<plugin>
<artifactId>maven-deploy-plugin</artifactId>
<version>2.8.2</version>
<configuration>
<skip>true</skip>
</configuration>
</plugin>
<plugin>
<artifactId>maven-project-info-reports-plugin</artifactId>
Expand All @@ -164,6 +167,46 @@
</execution>
</executions>
</plugin>
<plugin>
<!-- This is Pinterest deployment specific. -->
<!-- For non-Pinterest deployments, remove this block and use the maven-deploy-plugin instead. -->
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<version>3.0.0</version>
<executions>
<execution>
<id>artifactory-push-deploy</id>
<phase>deploy</phase>
<goals>
<goal>exec</goal>
</goals>
<configuration>
<executable>artifactory-push</executable>
<arguments>
<argument>maven</argument>
<argument>--env</argument>
<argument>prod</argument>
<argument>--maven_type</argument>
<argument>${deployment.type}</argument>
<argument>--maven_group_id</argument>
<argument>${project.groupId}</argument>
<argument>--maven_artifact_id</argument>
<argument>${project.artifactId}</argument>
<argument>--maven_version</argument>
<argument>${project.version}</argument>
<argument>--maven_pom</argument>
<argument>${project.file.path}</argument>
<argument>--maven_jar</argument>
<argument>${project.build.directory}/${project.build.finalName}.jar</argument>
<argument>--maven_jar_src</argument>
<argument>${project.build.directory}/${project.build.finalName}-sources.jar</argument>
<argument>--to_repo</argument>
<argument>maven-private-prod-sox-local</argument>
</arguments>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>

0 comments on commit fbb862b

Please sign in to comment.