Skip to content

Commit

Permalink
octez 21 + Quebec
Browse files Browse the repository at this point in the history
  • Loading branch information
cryi committed Nov 26, 2024
1 parent 7cc3969 commit e8cf91f
Show file tree
Hide file tree
Showing 12 changed files with 62 additions and 62 deletions.
34 changes: 17 additions & 17 deletions .github/workflows/containers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,32 +48,32 @@ jobs:
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2

- name: build tezos v20.3
- name: build tezos v21.0
uses: docker/build-push-action@v5
with:
file: containers/tezos/Containerfile
context: .
platforms: linux/amd64,linux/arm64
build-args: |
PROTOCOLS=PsParisC
IMAGE_TAG=octez-v20.3
PROTOCOLS=PsParisC,PsQuebec
IMAGE_TAG=octez-v21.0
GITHUB_TOKEN=${{ secrets.GITHUB_TOKEN }}
tags: ghcr.io/tez-capital/tezbox:tezos-v20.3.${{steps.prep.outputs.CURRENT_DATE}},ghcr.io/tez-capital/tezbox:tezos-v20.3,ghcr.io/tez-capital/tezbox:latest
tags: ghcr.io/tez-capital/tezbox:tezos-v21.0.${{steps.prep.outputs.CURRENT_DATE}},ghcr.io/tez-capital/tezbox:tezos-v21.0,ghcr.io/tez-capital/tezbox:latest
push: true
provenance: false

- name: build tezos v21.0-rc5
uses: docker/build-push-action@v5
with:
file: containers/tzc-tezos/Containerfile
context: .
platforms: linux/amd64,linux/arm64
build-args: |
PROTOCOLS=PsParisC,PsQ3NAxQ
IMAGE_TAG=latest
GITHUB_TOKEN=${{ secrets.GITHUB_TOKEN }}
tags: ghcr.io/tez-capital/tezbox:tezos-v21.0-rc5.${{steps.prep.outputs.CURRENT_DATE}},ghcr.io/tez-capital/tezbox:tezos-v21.0-rc5
push: true
provenance: false
# - name: build tezos v21.0-rc5
# uses: docker/build-push-action@v5
# with:
# file: containers/tzc-tezos/Containerfile
# context: .
# platforms: linux/amd64,linux/arm64
# build-args: |
# PROTOCOLS=PsParisC,PsQ3NAxQ
# IMAGE_TAG=latest
# GITHUB_TOKEN=${{ secrets.GITHUB_TOKEN }}
# tags: ghcr.io/tez-capital/tezbox:tezos-v21.0-rc5.${{steps.prep.outputs.CURRENT_DATE}},ghcr.io/tez-capital/tezbox:tezos-v21.0-rc5
# push: true
# provenance: false


36 changes: 18 additions & 18 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,32 +63,32 @@ jobs:
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2

- name: build tezos v20.3
- name: build tezos v21.0
uses: docker/build-push-action@v5
if: ${{ steps.prep.outputs.NEEDS_RELEASE == 'true'}}
with:
file: containers/tezos/Containerfile
context: .
platforms: linux/amd64,linux/arm64
build-args: |
PROTOCOLS=PsParisC
IMAGE_TAG=octez-v20.3
PROTOCOLS=PsParisC,PsQuebec
IMAGE_TAG=octez-v21.0
GITHUB_TOKEN=${{ secrets.GITHUB_TOKEN }}
tags: ghcr.io/tez-capital/tezbox:tezos-v20.3.${{steps.prep.outputs.CURRENT_DATE}},ghcr.io/tez-capital/tezbox:tezos-v20.3,ghcr.io/tez-capital/tezbox:latest
tags: ghcr.io/tez-capital/tezbox:tezos-v21.0.${{steps.prep.outputs.CURRENT_DATE}},ghcr.io/tez-capital/tezbox:tezos-v21.0,ghcr.io/tez-capital/tezbox:latest
push: true
provenance: false

- name: build tezos v21.0-rc5
uses: docker/build-push-action@v5
if: ${{ steps.prep.outputs.NEEDS_RELEASE == 'true'}}
with:
file: containers/tzc-tezos/Containerfile
context: .
platforms: linux/amd64,linux/arm64
build-args: |
PROTOCOLS=PsParisC,PsQ3NAxQ
IMAGE_TAG=latest
GITHUB_TOKEN=${{ secrets.GITHUB_TOKEN }}
tags: ghcr.io/tez-capital/tezbox:tezos-v21.0-rc5.${{steps.prep.outputs.CURRENT_DATE}},ghcr.io/tez-capital/tezbox:tezos-v21.0-rc5
push: true
provenance: false
# - name: build tezos v21.0-rc5
# uses: docker/build-push-action@v5
# if: ${{ steps.prep.outputs.NEEDS_RELEASE == 'true'}}
# with:
# file: containers/tzc-tezos/Containerfile
# context: .
# platforms: linux/amd64,linux/arm64
# build-args: |
# PROTOCOLS=PsParisC,PsQ3NAxQ
# IMAGE_TAG=latest
# GITHUB_TOKEN=${{ secrets.GITHUB_TOKEN }}
# tags: ghcr.io/tez-capital/tezbox:tezos-v21.0-rc5.${{steps.prep.outputs.CURRENT_DATE}},ghcr.io/tez-capital/tezbox:tezos-v21.0-rc5
# push: true
# provenance: false
6 changes: 0 additions & 6 deletions configuration/protocols/PsQ3NAxQ/protocol.hjson

This file was deleted.

6 changes: 6 additions & 0 deletions configuration/protocols/PsQuebec/protocol.hjson
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
id: psquebec
short: PsQuebec
hash: PsQuebecnLByd3JwTiGadoG4nGWi3HYiLXUjkibeFV8dCFeVMUg
aliases: [
quebecbox
]
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
"quorum_min": 2000,
"quorum_max": 7000,
"min_proposal_quorum": 500,
"liquidity_baking_subsidy": "0",
"liquidity_baking_subsidy": "5000000",
"liquidity_baking_toggle_ema_threshold": 1000000000,
"max_operations_time_to_live": 360,
"minimal_block_delay": "5",
Expand Down
2 changes: 1 addition & 1 deletion configuration/services/template/baker.hjson
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
TEZOS_LOG: "* -> info"
}
restart: always
restart_delay: 20
restart_delay: 10
restart_max_retries: 0 # unlimited
stop_timeout: 300
user: ${USER}
Expand Down
2 changes: 1 addition & 1 deletion containers/tezos/Containerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
ARG IMAGE_TAG=octez-v20.3
ARG IMAGE_TAG=octez-v21.0

FROM docker.io/tezos/tezos:${IMAGE_TAG}

Expand Down
2 changes: 1 addition & 1 deletion containers/tzc-tezos/Containerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
ARG IMAGE_TAG=octez-v20.3
ARG IMAGE_TAG=octez-v21.0

FROM ghcr.io/tez-capital/tezos:${IMAGE_TAG}

Expand Down
30 changes: 15 additions & 15 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,31 +23,31 @@ To use TezBox, you need to have OCI compatible container runtime installed on yo

```bash
# to run chain with the PsParisC protocol
docker run -it -p 0.0.0.0:8732:8732 ghcr.io/tez-capital/tezbox:tezos-v20.3 parisbox
docker run -it -p 0.0.0.0:8732:8732 ghcr.io/tez-capital/tezbox:tezos-v21.0 parisbox
# or to run in the background
docker run -d -p 0.0.0.0:8732:8732 ghcr.io/tez-capital/tezbox:tezos-v20.3 parisbox
docker run -d -p 0.0.0.0:8732:8732 ghcr.io/tez-capital/tezbox:tezos-v21.0 parisbox
```

You can list available protocols with the following command:
```bash
# docker run -it <image> list-protocols
docker run -it --entrypoint tezbox ghcr.io/tez-capital/tezbox:tezos-v20.3 list-protocols
docker run -it --entrypoint tezbox ghcr.io/tez-capital/tezbox:tezos-v21.0 list-protocols
```
#### Q3NA
#### Quebec

```bash
# to run chain with the Qena42 protocol
docker run -it -p 0.0.0.0:8732:8732 ghcr.io/tez-capital/tezbox:tezos-v21.0-rc5 q3nabox
docker run -it -p 0.0.0.0:8732:8732 ghcr.io/tez-capital/tezbox:tezos-v21.0 quebecbox
# or to run in the background
docker run -d -p 0.0.0.0:8732:8732 ghcr.io/tez-capital/tezbox:tezos-v21.0-rc5 q3nabox
docker run -d -p 0.0.0.0:8732:8732 ghcr.io/tez-capital/tezbox:tezos-v21.0 quebecbox
```

#### CI

`tezbox` is commonly used in CI pipelines. If you can estimate the expected duration of a specific test and want to prevent CI from getting stuck, you can use the `--timeout=<duration>` option to limit how long the instance runs. Supported units: `s` (seconds), `m` (minutes), `h` (hours). In case of a timeout, the container exits with an exit code of `2`.

```bash
docker run -it -p 0.0.0.0:8732:8732 ghcr.io/tez-capital/tezbox:tezos-v20.3 --timeout=120s parisbox
docker run -it -p 0.0.0.0:8732:8732 ghcr.io/tez-capital/tezbox:tezos-v21.0 --timeout=120s parisbox
```

Note: The timeout specifies how long the sandbox runs, excluding the bootstrap duration.
Expand All @@ -62,9 +62,9 @@ To run a dal within tezbox start tezbox with `--with-dal` option as follows:

```bash
# to run chain with the PsParisC protocol
docker run -it -p 0.0.0.0:8732:8732 ghcr.io/tez-capital/tezbox:tezos-v20.3 parisbox --with-dal
docker run -it -p 0.0.0.0:8732:8732 ghcr.io/tez-capital/tezbox:tezos-v21.0 parisbox --with-dal
# or to run in the background
docker run -d -p 0.0.0.0:8732:8732 ghcr.io/tez-capital/tezbox:tezos-v20.3 parisbox --with-dal
docker run -d -p 0.0.0.0:8732:8732 ghcr.io/tez-capital/tezbox:tezos-v21.0 parisbox --with-dal
```

### Configuration
Expand All @@ -83,15 +83,15 @@ minimal_block_delay: "1" // minimal block delay in seconds, has to be quoted
```
and run the container with the following command:
```bash
# docker run -it -v <path-to-your-file>:/tezbox/overrides/protocols/<case sensitive protocol id>/sandbox-parameters.hjson ... ghcr.io/tez-capital/tezbox:tezos-v20.3 oxfordbox
docker run -it -v $(pwd)/sandbox-override-parameters.hjson:/tezbox/overrides/protocols/Proxford/sandbox-parameters.hjson ... ghcr.io/tez-capital/tezbox:tezos-v20.3 oxfordbox
# docker run -it -v <path-to-your-file>:/tezbox/overrides/protocols/<case sensitive protocol id>/sandbox-parameters.hjson ... ghcr.io/tez-capital/tezbox:tezos-v21.0 oxfordbox
docker run -it -v $(pwd)/sandbox-override-parameters.hjson:/tezbox/overrides/protocols/Proxford/sandbox-parameters.hjson ... ghcr.io/tez-capital/tezbox:tezos-v21.0 oxfordbox
```
You can determine path based on folder structure in [configuration directory](https://github.com/tez-capital/tezbox/tree/main/configuration).

Optionally you can mount entire overrides/configuration directory to `/tezbox/overrides` or `/tezbox/configuration` to replace the whole configuration.

```bash
docker run -it -v <path-to-your-configuration-overrides>:/tezbox/overrides ... ghcr.io/tez-capital/tezbox:tezos-v20.3 oxfordbox
docker run -it -v <path-to-your-configuration-overrides>:/tezbox/overrides ... ghcr.io/tez-capital/tezbox:tezos-v21.0 oxfordbox
```

NOTE: **Do not edit or mount configuration files in the `/tezbox/context` directory. They are generated automatically and should not be modified manually.**
Expand Down Expand Up @@ -127,7 +127,7 @@ autostart: false
```
and mount it into overrides directory:
```bash
docker run -it -v $(pwd)/baker.hjson:/tezbox/overrides/services/baker.hjson ... ghcr.io/tez-capital/tezbox:tezos-v20.3 oxfordbox
docker run -it -v $(pwd)/baker.hjson:/tezbox/overrides/services/baker.hjson ... ghcr.io/tez-capital/tezbox:tezos-v21.0 oxfordbox
```

#### Chain Context
Expand All @@ -136,7 +136,7 @@ Chain and protocol is automatically initialized only once during the first run.

e.g.
```bash
docker run -it -v $(pwd)/sandbox-data:/tezbox -p 0.0.0.0:8732:8732 ghcr.io/tez-capital/tezbox:tezos-v20.3 oxfordbox
docker run -it -v $(pwd)/sandbox-data:/tezbox -p 0.0.0.0:8732:8732 ghcr.io/tez-capital/tezbox:tezos-v21.0 oxfordbox
```

NOTE: *To reset the state you can remove the `/tezbox/context/data/tezbox-initialized` file. After its removal all chain and client data will be removed and the chain will be reinitialized on the next run.*
Expand All @@ -157,7 +157,7 @@ To build TezBox follow these steps:
3. build lua sources (you can get eli [here](https://github.com/alis-is/eli/releases))
- `eli build/build.lua`
4. build the image
- `docker build --build-arg="PROTOCOLS=PsParisC" --build-arg="IMAGE_TAG=octez-v20.3" -t tezbox . -f containers/tezos/Containerfile --no-cache`
- `docker build --build-arg="PROTOCOLS=PsParisC" --build-arg="IMAGE_TAG=octez-v21.0" -t tezbox . -f containers/tezos/Containerfile --no-cache`

### Future development

Expand Down
2 changes: 1 addition & 1 deletion samples/multi-node_multi-dal/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@

To Run:

`docker run -v $(pwd)/samples/multi-node_multi-dal/overrides:/tezbox/overrides -it -p 0.0.0.0:8732:8732 ghcr.io/tez-capital/tezbox:tezos-v20.3 parisbox --with-dal`
`docker run -v $(pwd)/samples/multi-node_multi-dal/overrides:/tezbox/overrides -it -p 0.0.0.0:8732:8732 ghcr.io/tez-capital/tezbox:tezos-v21.0 parisbox --with-dal`
2 changes: 1 addition & 1 deletion src/version-info.lua
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
local TEZBOX_VERSION = "0.5.1"
local TEZBOX_VERSION = "0.6.0"

return {
VERSION = TEZBOX_VERSION,
Expand Down

0 comments on commit e8cf91f

Please sign in to comment.