From 85ee41a3a33312d47c7a44fcaea96269e4b84e73 Mon Sep 17 00:00:00 2001
From: biarca-shreya <96064595+biarca-shreya@users.noreply.github.com>
Date: Fri, 21 Apr 2023 16:07:14 +0530
Subject: [PATCH] Updated the maven settings for artifact registry in GCP
---
.travis.yml | 1 +
pom.xml | 27 +++++++++++++++++++------
travis/maven-settings.xml | 42 ++++++++++++++++++++++-----------------
3 files changed, 46 insertions(+), 24 deletions(-)
diff --git a/.travis.yml b/.travis.yml
index b2ce583..d60e096 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -21,6 +21,7 @@ stages:
before_install:
# Ensure the settings we want to use are in place before running the default mvn install
- cp ./travis/maven-settings.xml $HOME/.m2/settings.xml
+ - sed -i "s/-SNAPSHOT/-build-$TRAVIS_BUILD_NUMBER/" pom.xml
# Disable SourceClear except on scheduled builds
- |
if [ "$TRAVIS_EVENT_TYPE" != "cron" ]
diff --git a/pom.xml b/pom.xml
index 71d4a1f..a31f819 100644
--- a/pom.xml
+++ b/pom.xml
@@ -47,16 +47,25 @@
-
- io.cloudrepo.rit-public-snapshot
- https://susom.mycloudrepo.io/repositories/rit-public-snapshot
-
- ossrh
- https://oss.sonatype.org/service/local/staging/deploy/maven2/
+ artifact-registry
+ https://us-west1-maven.pkg.dev/som-rit-infrastructure-prod/public-maven
+
+
+ artifact-registry
+ https://us-west1-maven.pkg.dev/som-rit-infrastructure-prod/public-maven
+
+ true
+
+
+ false
+
+
+
+
@@ -420,6 +429,12 @@
${env.GPG_KEY_NAME}
${env.GPG_PASSPHRASE}
+
+
+ ossrh
+ https://oss.sonatype.org/service/local/staging/deploy/maven2/
+
+
diff --git a/travis/maven-settings.xml b/travis/maven-settings.xml
index 8bc08ce..bd818c5 100644
--- a/travis/maven-settings.xml
+++ b/travis/maven-settings.xml
@@ -5,7 +5,7 @@
- *,!io.cloudrepo.rit-public-snapshot,!io.cloudrepo.rit-ext-private
+ *,!artifact-registry
https://repo.maven.apache.org/maven2/
@@ -14,15 +14,8 @@
travis-ci
- io.cloudrepo.rit-public-snapshot
- https://susom.mycloudrepo.io/repositories/rit-public-snapshot
-
- true
-
-
-
- io.cloudrepo.rit-ext-private
- https://susom.mycloudrepo.io/repositories/rit-ext-private
+ artifact-registry
+ https://us-west1-maven.pkg.dev/som-rit-infrastructure-prod/public-maven
false
@@ -53,14 +46,27 @@
- io.cloudrepo.rit-public-snapshot
- ${env.REPO_USERNAME}
- ${env.REPO_API_TOKEN}
-
-
- io.cloudrepo.rit-ext-private
- ${env.REPO_USERNAME}
- ${env.REPO_API_TOKEN}
+ artifact-registry
+
+
+
+ true
+
+
+ true
+
+
+
+
+ http.protocol.expect-continue
+ false
+
+
+
+
+
+ _json_key_base64
+ ${env.ARTIFACT_REGISTRY_KEY}
ossrh