New Flextesa Docker Image And Some Development News
We pushed a fresh docker image for Flextesa’s “easy to spin-up sandboxes:” tqtezos/flextesa:20210930
.
As always, it is built on top of the flextesa
executable and the Octez suite, and has the *box
scripts which made its fame:
For instance:
$ docker run --rm --name my-sandbox --detach -p 20000:20000 \
tqtezos/flextesa:20210930 granabox start
The assets-portal is now deprecated but the sandbox tutorial at https://assets.tqtezos.com/docs/setup/2-sandbox/ is still relevant.
Let’s Try The Hangzhou Protocol
The new Docker image also contains a hangzbox
script:
$ docker run --rm --name my-sandbox --detach -p 20000:20000 \
tqtezos/flextesa:20210930 hangzbox start
You need a Hangzhou-compatible tezos-client
implementation (check tezos-client list understood protocols
for PtHangzHogok
); you may use the one in the Docker container:
alias tzclient='docker exec my-sandbox tezos-client'
$ tzclient --endpoint http://localhost:20000 config update# The famous `alice` is there:
$ tzclient get balance for tz1VSUr8wwNhLAzempoch5d6hLRiTh8Cjcjb
2000000 ꜩ
On can then check that the protocol hash is PtHangzHogokSuiMHemCuowEavgYTP8J5qQ9fQS793MHYFpCY3r
:
$ tzclient rpc get /chains/main/blocks/head/metadata | grep protocol{ "protocol": "PtHangzHogokSuiMHemCuowEavgYTP8J5qQ9fQS793MHYFpCY3r",
"next_protocol": "PtHangzHogokSuiMHemCuowEavgYTP8J5qQ9fQS793MHYFpCY3r",
or that the new cache for contracts is available:
$ tzclient rpc get /chains/main/blocks/head/context/cache/contracts/size
293821
This is indeed Hangzhou!
When you’re done playing, just destroy the container:
docker kill my-sandbox
Next For Flextesa
We always welcome contributions, over the next few months, we’ll try to improve usability on these two fronts:
- Making the governance scenarios easier to use by third party users.
- Making the “Mondaynet” version of protocol “alpha” available as well.
Right now both are available in the Octez repository (for historical reasons) and require manual building.
Further Reading
For more issues or questions, see the Flextesa repository, and for even more advanced usage, see the documentation (esp. for the mini-net
command).