From 0008f663dab70331ba98e71007ec25fe7e006491 Mon Sep 17 00:00:00 2001 From: Jan Pokorný Date: Wed, 8 Jan 2014 23:45:41 +0100 Subject: Firstrun scripts: 00-certs-common: add npm cert to npm bundle MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Jan Pokorný --- scripts/firstrun/00-certs-common | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/scripts/firstrun/00-certs-common b/scripts/firstrun/00-certs-common index cd1e754..2c496c9 100644 --- a/scripts/firstrun/00-certs-common +++ b/scripts/firstrun/00-certs-common @@ -1,5 +1,7 @@ pushd ../certs >/dev/null +source ./cert-def + # Fedora project authority # ./cert-import homebundle admin.fedoraproject.org # good to do first? ./cert-import homebundle firefox https://admin.fedoraproject.org/ca/cacert.pem @@ -15,4 +17,11 @@ pushd ../certs >/dev/null https://www.digicert.com/CACerts/DigiCertHighAssuranceEVCA-1.crt ./cert-import homebundle -nocrl www.github.com +# npm (prerequisite: GitHub) +NPMCA_SRC="https://raw.github.com/isaacs/npm/master/node_modules/npmconf/config-defs.js" +wget -nv --ca-certificate "${HOMEBUNDLE}" -O - -- "${NPMCA_SRC}" \ + | sed -n '120,135{s|^\s\+\(\[\s*\)\?\"\([^\"]\+\)\\n\"[+,]|\2|g;p}' \ + >> "${CA_BUNDLE_NPM}" +unset NPMCA_SRC + popd >/dev/null -- cgit