ort icon indicating copy to clipboard operation
ort copied to clipboard

Maven private repository

Open remi-cogito opened this issue 2 years ago • 5 comments

How to set up docker image to authenticate with private maven repository?

remi-cogito avatar Nov 27 '23 17:11 remi-cogito

Please see https://oss-review-toolkit.org/ort/docs/guides/docker#authenticating-with-a-private-git-repository-fails which describes the solution based on a .netrc file. You basically need the same, but with a Maven settings.xml file mounted to ~/.m2/settings.xml inside the container.

sschuberth avatar Nov 27 '23 19:11 sschuberth

I have tried with /home/ort/.m2/settings.xml and ~/.m2/settings.xmland /root/.m2/settings.xml, it did not work.

status code: 401, reason phrase:  (401) and 'parent.relativePath' points at no local POM @ line 19, column 13

I could run mvn clean package successfully in this container, but ort analyze failed. Any dependency in private jfrog could not be downloaded.

BinchenQ avatar Dec 21 '23 02:12 BinchenQ

I am also facing the same issue as described by @BinchenQ.

@sschuberth: Can you please advise here, thanks

arunsmartarrow avatar Feb 22 '24 21:02 arunsmartarrow

status code: 401, reason phrase: (401) and 'parent.relativePath' points at no local POM @ line 19, column 13

In this specific case from @BinchenQ it seems like the parent POM is hosted elsewhere, like another host, which might require different authentication than the primary project under analysis. Hard to say without more details...

sschuberth avatar Feb 22 '24 21:02 sschuberth