Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

nuget command line utility package restore with mono on ubuntu

I'm trying to restore packages with the nuget restore command using the nuget.exe command line utility.

I'm on Ubuntu 14.04, and have just performed apt-get update.

Calling mono --version returns: Mono JIT compiler version 3.2.8 (Debian 3.2.8+dfsg-4ubuntu1)

Here is my exact call and response:

$ mono nuget.exe restore
WARNING: The initialization function tries to access Value on this instance
WARNING: The initialization function tries to access Value on this instance
WARNING: The initialization function tries to access Value on this instance
WARNING: Error getting response stream (Write: The authentication or decryption has failed.): SendFailure
Unable to find version '2.0.14' of package 'FSharp.Data'.
Unable to find version '1.3.0.1' of package 'FsUnit'.
Unable to find version '1.3.0.1' of package 'FsUnit.Sample'.
Unable to find version '2.6.3' of package 'NUnit'.

I have tried with and without a nuget.config file in the same folder.

What's going wrong and what can I do to solve?

like image 695
Nick Avatar asked Dec 07 '25 10:12

Nick


1 Answers

The problem you describe has to do with root security certificates.

Enter the following command in your terminal:

mozroots --import --sync

As per @ahri below, here is a more up-to-date answer:

mozroots --import --sync --url https://hg.mozilla.org/mozilla-central/raw-file/tip/security‌​/nss/lib/ckfw/builti‌​ns/certdata.txt

Source

like image 98
seyisulu Avatar answered Dec 10 '25 04:12

seyisulu



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!