Skip to content

Commit d67b14b

Browse files
committed
Custom scripts, web terminal, welcome message
1 parent 7ff5ec1 commit d67b14b

File tree

13 files changed

+128
-16
lines changed

13 files changed

+128
-16
lines changed

README.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
Cryptotux is a Linux image preconfigured with tools for crypto development and education.
44

5-
Cryptotux is currently supplied as .ova images that can be directly imported into Virtualbox (6.X+).
5+
Cryptotux is currently supplied as .ova images that can be directly imported into Virtualbox (6.X+) and VMWare.
66
It is particularly suited for workshops. Username is *bobby*, password is *bricodeur*.
77

88
![screenshot](screenshot.png)
@@ -24,7 +24,8 @@ To launch only nodes or tooling you can use the server version.
2424
* Install [virtualbox](https://virtualbox.org)
2525
* Download the latest "Server image" on [cryptotux.org](https://cryptotux.org)
2626
* Click on the file or on "↶ import appliance" in virtualbox
27-
* Connect via ssh `ssh bobby@192.168.33.10 ` (add `-o IdentitiesOnly=yes` if you have many keys) <!-- or have a preview by opening a browser at http://192.168.33.10:3030 -->
27+
* Connect via ssh `ssh bobby@192.168.33.10 ` (add `-o IdentitiesOnly=yes` if you have many keys)
28+
* Or open a browser at http://192.168.33.10:7681/
2829

2930
For ease you can also sync a local folder, let's call it 'remote', and the internal user folder of the machine with `sshfs -o IdentitiesOnly=yes bobby@192.168.33.10:/home/bobby ~/remote`
3031

assets/.bitcoin/bitcoin.conf

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,4 +13,5 @@ rpcuser=bobby
1313
rpcpassword=bricodeur
1414
rpcallowip=127.0.0.1
1515

16-
16+
zmqpubrawblock=tcp://127.0.0.1:28332
17+
zmqpubrawtx=tcp://127.0.0.1:28333

assets/.cryptotux/scripts/clean.sh

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,17 @@ echo ">> Warning : Script designed for light image release, might be harsh for u
44
sudo apt-get autoclean -y;
55
sudo apt-get -y clean;
66
sudo apt-get -y --purge autoremove;
7-
bleachbit -c --preset
7+
# bleachbit -c --preset
88
rm -rf ~/.cache/thumbnails/*
99
sudo rm -rf /var/log/*
1010
sudo rm -rf /home/*/.local/share/Trash/*
1111
sudo rm -rf /root/.local/share/Trash/*
12+
sudo find /tmp -type f -atime +1 -delete
13+
1214
dd if=/dev/zero of=/var/tmp/bigemptyfile bs=4096k
1315
rm /var/tmp/bigemptyfile
16+
17+
rm .cryptotux/greeted
1418
rm ~/.bash_history
15-
history -c
19+
20+
echo ">>> Cleaning done <<<"

assets/.cryptotux/scripts/libra.sh

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
#!/bin/bash
2+
3+
mkdir ~/Projects/
4+
cd ~/Projects/
5+
git clone https://github.com/libra/libra.git
6+
cd libra
7+
git checkout testnet
8+
yes | ./scripts/dev_setup.sh
9+
./scripts/cli/start_cli_testnet.sh
10+
libraAlias="alias libra=~/Projects/libra//scripts/cli/start_cli_testnet.sh"
11+
$libraAlias
12+
echo $libraAlias >> ~/.bashrc
13+
echo -e '\033[1mLibra installed\033[0m'
14+
libra
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
#!/bin/bash
2+
mkdir -p ~/Projects/
3+
cd ~/Projects/
4+
git clone https://github.com/bitcoin/bitcoin.git Bitcoin
5+
6+
go get -u github.com/golang/dep/cmd/dep
7+
go get -d github.com/lightningnetwork/lnd
8+
cd $GOPATH/src/github.com/lightningnetwork/lnd
9+
make && make install
10+
make check
11+
# TODO add better configuration and walktrough
12+
echo -e '\033[1mBitcoin source and Lightning node installed\033[0m'
13+
echo -e 'launch \033[1mbitcoind \033[0min one terminal and in another one'
14+
echo -e '\033[1mlnd --bitcoin.active --bitcoin.testnet --debuglevel=debug --bitcoin.node=bitcoind --bitcoind.rpcuser=bobby --bitcoind.rpcpass=bricodeur --bitcoind.zmqpubrawblock=tcp://127.0.0.1:28332 --bitcoind.zmqpubrawtx=tcp://127.0.0.1:28333\033[0m'
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
#!/bin/bash
2+
3+
echo export GO111MODULE=on >> ~/.bash_profile
4+
mkdir -p $GOPATH/src/github.com/tendermint
5+
cd $GOPATH/src/github.com/tendermint
6+
git clone https://github.com/tendermint/tendermint.git
7+
cd tendermint
8+
make tools
9+
make install
10+
echo -e '\033[1mTendermint is ready to be used.\033[0m'
11+
echo "Version : $(tendermint version)"
12+

assets/.cryptotux/scripts/tezos.sh

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
#!/bin/bash
2+
tezosHome="~/Projects/Tezos"
3+
mkdir -p $tezosHome
4+
cd $tezosHome
5+
wget -O carthagenet.sh https://gitlab.com/tezos/tezos/raw/latest-release/scripts/tezos-docker-manager.sh
6+
chmod +x carthagenet.sh
7+
tezosAlias="alias tezos=$tezosHome/carthagenet.sh"
8+
$tezosAlias
9+
echo $tezosAlias >> ~/.bashrc
10+
tezos start
11+
cd
12+
echo -e '\033[1mNode is launched and syncing to Tezos testnet \e[92mCarthagenet\e[39m \033[0m'
13+
echo "Next steps:"
14+
echo "- Claim some testnest tezzies on https://faucet.tzalpha.net/"
15+
echo -e "- \033[1mtezos client\033[0m to connect to the node (tezos-client in the documentation)"
16+
echo -e "- \033[1mtezos node stop \033[0mto stop the node"

assets/.cryptotux/scripts/ttyd.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
#!/bin/bash
2+
/home/bobby/.cryptotux/

assets/.cryptotux/scripts/update.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@ npm update -g
88
echo ">> Update local git repositories"
99
cd /home/bobby/Tutorials
1010
for i in */.git; do ( echo "> $i ";cd $i/..; git pull;); done;
11-
cd ~/Cryptotux-respository
12-
git pull
11+
cd ~/Projects/
12+
for i in */.git; do ( echo "> $i ";cd $i/..; git pull;); done;
1313
# TODO : update tooling based on the new versions in cryptotux
1414
cd
15-
echo ">> Update done "
15+
echo ">>> Update done <<<"

assets/.cryptotux/scripts/versions.sh

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ echo ${vv#"Description:"}
77

88
echo -e "\n Languages"
99
# python -V # deprecated
10+
gcc --version | head -n 1
1011
python3 -V
1112
go version
1213
rustc --version
@@ -16,6 +17,7 @@ echo -e "\n Tooling"
1617
docker --version
1718
echo "geth" $(geth version | sed -n 2p)
1819
bitcoind --version | head -n 1
20+
# Optionnal installs
21+
[ -x "$(command -v tendermint)" ] && tendermint version
1922

20-
echo ">> done <<"
21-
23+
echo ">>> done <<<"

0 commit comments

Comments
 (0)