Skip to content

Commit

Permalink
[Chore] Deprecate nairobinet
Browse files Browse the repository at this point in the history
Problem: Nairobinet is down.

Solution: Remove nairobinet support and update protocols for existing testnets.
  • Loading branch information
krendelhoff2 committed Feb 14, 2024
1 parent c2924a4 commit a8f707e
Show file tree
Hide file tree
Showing 13 changed files with 41 additions and 112 deletions.
4 changes: 2 additions & 2 deletions .buildkite/pipeline-raw.yml
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ steps:
- eval "$SET_VERSION"
# Building all binary packages will take significant amount of time, so we build only one
# in order to ensure package generation sanity
- nix develop .#docker-tezos-packages -c ./docker/build/ubuntu/build.py --type binary -p tezos-baker-PtNairob
- nix develop .#docker-tezos-packages -c ./docker/build/ubuntu/build.py --type binary -p tezos-baker-Proxford
- rm -rf out
# It takes much time to build binary package, so we do it only on master
branches: "master"
Expand Down Expand Up @@ -144,7 +144,7 @@ steps:
- eval "$SET_VERSION"
# Building all binary packages will take significant amount of time, so we build only one
# in order to ensure package generation sanity
- nix develop .#docker-tezos-packages -c ./docker/build/fedora/build.py --type binary -p tezos-baker-PtNairob
- nix develop .#docker-tezos-packages -c ./docker/build/fedora/build.py --type binary -p tezos-baker-Proxford
- rm -rf out
# It takes much time to build binary package, so we do it only on master
branches: "master"
Expand Down
66 changes: 0 additions & 66 deletions Formula/tezos-node-nairobinet.rb

This file was deleted.

3 changes: 1 addition & 2 deletions baking/src/tezos_baking/steps.py
Original file line number Diff line number Diff line change
Expand Up @@ -105,8 +105,7 @@ def pprint_options(self):

networks = {
"mainnet": "Main Tezos network",
"ghostnet": "Long running test network, currently using the Nairobi Tezos protocol",
"nairobinet": "Test network using the Nairobi Tezos protocol",
"ghostnet": "Long running test network, currently using the Oxford Tezos protocol",
"oxfordnet": "Test network using the Oxford2 Tezos protocol",
}

Expand Down
2 changes: 1 addition & 1 deletion baking/src/tezos_baking/tezos_setup_wizard.py
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@ def network_name_or_teztnets_url(network):
id="network",
prompt="Which Tezos network would you like to use?\nCurrently supported:",
help="The selected network will be used to set up all required services.\n"
"The currently supported protocol is `PtNairob` (used on `nairobinet`, `ghostnet` and `mainnet`) and Proxford (used on `oxfordnet`).\n"
"The currently supported protocol is Proxford (used on `oxfordnet`, `ghostnet` and `mainnet`).\n"
"Keep in mind that you must select the test network (e.g. ghostnet)\n"
"if you plan on baking with a faucet JSON file.\n",
options=networks,
Expand Down
6 changes: 2 additions & 4 deletions docker/package/packages.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,11 @@
networks = {
"mainnet": "mainnet",
"ghostnet": "ghostnet",
"nairobinet": "https://teztnets.com/nairobinet",
"oxfordnet": "https://teztnets.com/oxfordnet",
}
networks_protos = {
"mainnet": ["PtNairob"],
"ghostnet": ["PtNairob"],
"nairobinet": ["PtNairob"],
"mainnet": ["Proxford"],
"ghostnet": ["Proxford"],
"oxfordnet": ["Proxford"],
}

Expand Down
6 changes: 2 additions & 4 deletions docker/tests/binaries.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
{
"released": [
"tezos-smart-rollup-client-Proxford",
"tezos-smart-rollup-client-PtNairob",
"tezos-smart-rollup-node",
"tezos-smart-rollup-wasm-debugger"
"tezos-baking",
"tezos-sapling-params",
"tezos-accuser-Proxford",
Expand All @@ -15,8 +14,7 @@
"tezos-codec",
"tezos-signer",
"tezos-admin-client",
"tezos-client",
"tezos-smart-rollup-wasm-debugger"
"tezos-client"
],
"candidates": [
"tezos-smart-rollup-node",
Expand Down
5 changes: 3 additions & 2 deletions docs/baking.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ that you can use by following the [installation instructions](https://www.raspbe
In order to run a baking instance, you'll need the following Tezos binaries:
`tezos-client`, `tezos-node`, `tezos-baker-<proto>`.

The currently supported protocol is `PtNairob` (used on `nairobinet`, `ghostnet` and `mainnet`) and `Proxford` (used on `oxfordnet`).
The currently supported protocol is `Proxford` (used on `oxfordnet`, `ghostnet` and `mainnet`).
Also, note that the corresponding packages have protocol
suffix in lowercase, e.g. the list of available baker packages can be found
[here](https://launchpad.net/~serokell/+archive/ubuntu/tezos/+packages?field.name_filter=tezos-baker&field.status_filter=published).
Expand Down Expand Up @@ -115,8 +115,9 @@ which will take a significant amount of time.
In order to avoid this, we suggest bootstrapping from a snapshot instead.

Snapshots can be downloaded from the following websites:
* [XTZ-Shots](https://xtz-shots.io/)
* [Lambs on acid](https://lambsonacid.nl/)
* [Marigold](https://snapshots.tezos.marigold.dev/)
* [Tzinit](https://snapshots.eu.tzinit.org/)

Download the snapshot for the desired network. We recommend to use rolling snapshots. This is
the smallest and the fastest mode that is sufficient for baking (you can read more about other
Expand Down
4 changes: 2 additions & 2 deletions docs/fedora.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@ following commands:
# use dnf
sudo dnf copr enable @Serokell/Tezos
sudo dnf install tezos-client
sudo dnf install tezos-baker-PtNairob
sudo dnf install tezos-baker-Proxford
# or use yum
sudo yum copr enable @Serokell/Tezos
sudo yum install tezos-baker-PtNairob
sudo yum install tezos-baker-Proxford
```
Once you install these packages, the commands `tezos-*` and `octez-*` will be available.

Expand Down
5 changes: 2 additions & 3 deletions docs/systemd.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ Then you can use the script, specifying the binary name as an argument, e.g.:
```
./gen_systemd_service_file.py tezos-node
# or
./gen_systemd_service_file.py tezos-baker-PtNairob
./gen_systemd_service_file.py tezos-baker-Proxford
```
After that you'll have `.service` files in the current directory.

Expand All @@ -62,7 +62,6 @@ It's possible to run multiple similar services, e.g. two `tezos-node`s that run
networks.

`tezos-node` packages provide multiple services out of the box:
- `tezos-node-nairobinet`
- `tezos-node-oxfordnet`
- `tezos-node-ghostnet`
- `tezos-node-mainnet`
Expand All @@ -78,7 +77,7 @@ Also, there are `tezos-node-<network>` binary aliases that are equivalent to
running `tezos-node` with [the service options](./configuration.md) given.

In addition to node services where the config is predefined to a specific network
(e.g. `tezos-node-mainnet` or `tezos-node-nairobinet`), it's possible to run
(e.g. `tezos-node-mainnet` or `tezos-node-oxfordnet`), it's possible to run
`tezos-node-custom` service.

Another case for running multiple similar systemd services is when one wants to have
Expand Down
2 changes: 1 addition & 1 deletion docs/voting.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,5 +52,5 @@ tezos-vote --network voting
`tezos-vote` also supports voting on currently running testnets, for example:

```bash
tezos-vote --network nairobinet
tezos-vote --network oxfordnet
```
42 changes: 21 additions & 21 deletions tests/systemd/services_tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -128,16 +128,16 @@ def test_node_mainnet_service():
node_service_test("mainnet")


def test_node_nairobinet_service():
node_service_test("nairobinet")
def test_node_oxfordnet_service():
node_service_test("oxfordnet")


def test_baking_nairobinet_service():
baking_service_test("nairobinet", ["PtNairob"])
def test_baking_oxfordnet_service():
baking_service_test("oxfordnet", ["Proxford"])


def test_baking_mainnet_service():
baking_service_test("mainnet", ["PtNairob"])
baking_service_test("mainnet", ["Proxford"])


def test_http_signer_service():
Expand All @@ -149,9 +149,9 @@ def test_tcp_signer_service():


def test_standalone_accuser_service():
with unit(f"tezos-node-nairobinet.service") as _:
with unit(f"tezos-accuser-ptnairob.service") as _:
assert check_running_process(f"octez-accuser-PtNairob")
with unit(f"tezos-node-oxfordnet.service") as _:
with unit(f"tezos-accuser-proxford.service") as _:
assert check_running_process(f"octez-accuser-Proxford")


def test_unix_signer_service():
Expand All @@ -161,34 +161,34 @@ def test_unix_signer_service():

def test_standalone_baker_service():
replace_systemd_service_env(
"tezos-baker-ptnairob",
"tezos-baker-proxford",
"TEZOS_NODE_DIR",
"/var/lib/tezos/node-nairobinet",
"/var/lib/tezos/node-oxfordnet",
)
with account("baker") as _:
with unit(f"tezos-node-nairobinet.service") as _:
with unit(f"tezos-baker-ptnairob.service") as _:
assert check_active_service(f"tezos-baker-ptnairob.service")
assert check_running_process(f"octez-baker-PtNairob")
with unit(f"tezos-node-oxfordnet.service") as _:
with unit(f"tezos-baker-proxford.service") as _:
assert check_active_service(f"tezos-baker-proxford.service")
assert check_running_process(f"octez-baker-Proxford")


def test_nondefault_node_rpc_endpoint():
rpc_addr = "127.0.0.1:8735"
replace_systemd_service_env("tezos-node-nairobinet", "NODE_RPC_ADDR", rpc_addr)
proc_call("cat /etc/default/tezos-node-nairobinet")
replace_systemd_service_env("tezos-node-oxfordnet", "NODE_RPC_ADDR", rpc_addr)
proc_call("cat /etc/default/tezos-node-oxfordnet")
try:
node_service_test("nairobinet", f"http://{rpc_addr}")
node_service_test("oxfordnet", f"http://{rpc_addr}")
finally:
replace_systemd_service_env(
"tezos-node-nairobinet", "NODE_RPC_ADDR", "127.0.0.1:8732"
"tezos-node-oxfordnet", "NODE_RPC_ADDR", "127.0.0.1:8732"
)


def test_nondefault_baking_config():
replace_systemd_service_env(
"tezos-baking-nairobinet", "BAKER_ADDRESS_ALIAS", "another_baker"
"tezos-baking-oxfordnet", "BAKER_ADDRESS_ALIAS", "another_baker"
)
replace_systemd_service_env(
"tezos-baking-nairobinet", "LIQUIDITY_BAKING_TOGGLE_VOTE", "on"
"tezos-baking-oxfordnet", "LIQUIDITY_BAKING_TOGGLE_VOTE", "on"
)
baking_service_test("nairobinet", ["PtNairob"], "another_baker")
baking_service_test("oxfordnet", ["Proxford"], "another_baker")
4 changes: 2 additions & 2 deletions tests/tezos-binaries.nix
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ in import "${nixpkgs}/nixos/tests/make-test-python.nix" ({ ... }: {

testScript = ''
path_to_binaries = "${path-to-binaries}"
octez_accuser = f"{path_to_binaries}/octez-accuser-PtNairob"
octez_accuser = f"{path_to_binaries}/octez-accuser-Proxford"
octez_admin_client = f"{path_to_binaries}/octez-admin-client"
octez_baker = f"{path_to_binaries}/octez-baker-PtNairob"
octez_baker = f"{path_to_binaries}/octez-baker-Proxford"
octez_client = f"{path_to_binaries}/octez-client"
octez_node = f"{path_to_binaries}/octez-node"
octez_signer = f"{path_to_binaries}/octez-signer"
Expand Down
4 changes: 2 additions & 2 deletions tests/tezos-modules.nix
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,12 @@ let

octez-accuser = {
enable = true;
baseProtocols = ["PtNairob"];
baseProtocols = ["Proxford"];
};

octez-baker = {
enable = true;
baseProtocols = ["PtNairob"];
baseProtocols = ["Proxford"];
bakerAccountAlias = "baker";
bakerSecretKey = "unencrypted:edsk3KaTNj1d8Xd3kMBrZkJrfkqsz4XwwiBXatuuVgTdPye2KpE98o";
};
Expand Down

0 comments on commit a8f707e

Please sign in to comment.