diff --git a/bin/installbfa.sh b/bin/installbfa.sh index 1a28d634d6772f43f1648f7a7508b7452c1ca826..8387c8522bcef4297f20cdbefe262f0564067f86 100755 --- a/bin/installbfa.sh +++ b/bin/installbfa.sh @@ -146,15 +146,20 @@ function usersetup info Adding required user \"bfa\" adduser --disabled-password --gecos 'Blockchain Federal Argentina' bfa fi - cd ~bfa + # If we're running inside a docker, this may already exist but + # probably owned by root. Let's make sure things are proper. + chown -R bfa:bfa ~bfa # cloning if not done already if [ ! -d ~bfa/bfa ] then + # initial cloning + cd ~bfa git clone https://gitlab.bfa.ar/blockchain/nucleo.git bfa + else + # updating + cd ~bfa/bfa + git pull fi - # updating - cd ~bfa/bfa - git pull # cd ~bfa if [ $( expand < .bashrc | grep -E 'source .*bfa/bin/env' | wc -l ) -eq 0 ] @@ -182,6 +187,7 @@ function welcome # Ubuntu necesita mas repos grep -q Ubuntu /etc/issue && apt-add-repository multiverse +# apt update # development tools aptinstall dirmngr apt-transport-https curl git curl build-essential sudo