Skip to content
Snippets Groups Projects
Commit 1b18f8da authored by Robert Martin-Legene's avatar Robert Martin-Legene
Browse files

instalacion de modulos npm mas sincillos.

parent 517188f7
No related branches found
No related tags found
No related merge requests found
......@@ -11,3 +11,4 @@ test2network*/node
test2network*/bootnode
test2network*/contracts/*
test2network/*.pid
node_modules
#!/bin/bash -x
trap "exit 1" ERR
wget https://gitlab.bfa.ar/blockchain/nucleo/raw/master/bin/installbfa.sh
chmod 755 installbfa.sh
./installbfa.sh
......@@ -34,10 +34,10 @@ function runasownerof
pushd $path > /dev/null
if [ $( stat --format=%u . ) -ne $UID ]
then
precmd="sudo --preserve-env=PATH --set-home -u $( stat --format=%U . )"
precmd="sudo --preserve-env --set-home -u $( stat --format=%U . )"
fi
unset path
${precmd} "$@"
${precmd} "PATH=${PATH}" "$@"
rv=$?
popd > /dev/null
unset precmd
......@@ -64,26 +64,8 @@ function nodejsinstall
fi
# nodejs also provides npm
aptinstall nodejs
# init npm
test -r ~bfa/package.json ||
info "Initialising nodejs." &&
runasownerof ~bfa npm init -y
# nodejs package(s) that we need.
if ! runasownerof ~bfa npm ls require > /dev/null
then
info "Installing nodejs module: require"
runasownerof ~bfa npm install require
fi
if ! runasownerof ~bfa npm ls request > /dev/null
then
info "Installing nodejs module: request"
runasownerof ~bfa npm install request
fi
if ! runasownerof ~bfa npm ls web3 > /dev/null
then
info "Installing nodejs module: web3 (will show many warnings)"
runasownerof ~bfa npm install web3
fi
info "Installing nodejs modules (will show many warnings)"
runasownerof ${BFAHOME} npm install
}
function golanginstall
......
This diff is collapsed.
{
"name": "bfa",
"version": "1.0.0",
"description": "Blockchain Federal Argentina",
"dependencies": {
"request": "^2.88.0",
"require": "^2.4.20",
"web3": "^1.0.0-beta.55"
},
"repository": {
"type": "git",
"url": "https://gitlab.bfa.ar/blockchain/nucleo.git"
},
"author": "Robert Martin-Legene",
"license": "GPL-2.0-only"
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment