I follow the following commands in order to install Tezos.
sudo apt-get update \
&& sudo apt-get upgrade \
&& sudo apt install -y rsync git m4 build-essential patch unzip bubblewrap wget pkg-config libgmp-dev libev-dev libhidapi-dev ntp rng-tools\
&& echo "HRNGDEVICE=/dev/urandom" | sudo tee -a /etc/default/rng-tools \
&& /etc/init.d/rng-tools start \
&& wget https://github.com/ocaml/opam/releases/download/2.0.5/opam-2.0.5-x86_64-linux \
&& sudo cp opam-2.0.5-x86_64-linux /usr/local/bin/opam \
&& sudo chmod a+x /usr/local/bin/opam \
&& git clone https://gitlab.com/tezos/tezos.git \
&& cd tezos \
&& git checkout carthagenet \
&& opam init --bare \
&& opam switch create tezos ocaml-base-compiler.4.07.1 \
&& eval $(opam env) \
&& make build-deps \
&& eval $(opam env) \
&& make \
&& ~/tezos/tezos-node identity generate
I have also tried other recipes from the Tezos website or medium articles. When I enter the commands in bash one after another, everything works fine. However, for my research I need to automatically set up larger numbers of nodes from scratch, so I need a fully automatic setup. When I execute a single bash script containing all the above commands, the make
command fails. All steps before seem to succeed. When I continue with make
manually after the script aborts, everything works as expected. Moreover, when I execute eval $(opam env) && cd tezos && make
via ssh, all seems to be fine, however, at a later stage, when I run the sandboxed client, I cannot connect to the sandboxed nodes. When I run make
from the terminal before, the sandboxed stuff works out nicely.
Please see below the terminal output before the script fails to execute the make
command. All has been repeatedly tested on a fresh installation of Ubuntu 18.04 where only docker has been installed.
Help would be very much appreciated. Thanks!
opam switch create tezos ocaml-base-compiler.4.07.1
, I've never used when compiling tezos. You might also want to trymake build-deps && eval $(opam env) && make
as a separate one-liner, as that is the typical "rebuild" instruction for new versions.