1

I'm trying to to install R packages from artifactory and also i need to authenticate but im not sure how i can pass credentials to the install.packages in R :

the below is what i tried but it doesnt work, however when i tried to use curl to query for the same file it works :

install.packages('broom',repos="http://user:pass@artifactory-url:port/artifactory/cran/",method=curl,verbose="true")

output :

Warning: unable to access index for repository http://user:pass@artifactory-url:port/artifactory/cran/src/contrib: cannot open URL 'http://user:pass@artifactory-url:port/artifactory/cran/src/contrib/PACKAGES' Warning message: package ‘broom’ is not available (for R version 3.3.2)

1
  • AFAIK you should pass the API key as "pass" (which you can create in the web UI after logging in, choosing "edit profile" and clicking on the "copy" icon of the API key. Important: To avoid leaking your personal API key you should store it in a credential store and build the URL using the credential store (eg. by using the package keyring) Commented Jul 8, 2021 at 9:36

1 Answer 1

1

Artifactory supports CRAN repos for R Packages, you can find the documentation here

Sign up to request clarification or add additional context in comments.

1 Comment

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.