Skip to content

Commit 614cc6d

Browse files
docs(l1): move install instructions to new section and embed script one-liner (#3505)
**Motivation** Since the install script just builds from source using a `cargo install` one-liner, it's preferable to show that instead of having to download and run an install script. **Description** This PR removes the install script, embedding the one-liner inside the docs. It also moves the installation instructions to the book, linking to it in the readme, and expands them with instructions on how to build from source or download the pre-built binaries. --------- Co-authored-by: Manuel Iñaki Bilbao <manuel.bilbao@lambdaclass.com>
1 parent 212d72a commit 614cc6d

File tree

6 files changed

+144
-41
lines changed

6 files changed

+144
-41
lines changed

README.md

Lines changed: 2 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -8,30 +8,9 @@ Minimalist, stable, modular and fast implementation of the Ethereum protocol in
88
[tg-badge]: https://img.shields.io/endpoint?url=https%3A%2F%2Ftg.sumanjay.workers.dev%2Fethrex_client%2F&logo=telegram&label=chat&color=neon
99
[tg-url]: https://t.me/ethrex_client
1010

11-
## Quick-start
11+
## Getting started
1212

13-
To install the client, [first install Rust](https://www.rust-lang.org/tools/install) and run:
14-
15-
```sh
16-
curl -sSL https://raw.githubusercontent.com/lambdaclass/ethrex/refs/heads/main/install.sh | sh
17-
```
18-
19-
This installs the `ethrex` binary.
20-
21-
### Starting the L1
22-
23-
After running the install script, you can start the L1 by running:
24-
25-
```sh
26-
ethrex --dev
27-
```
28-
29-
> [!TIP]
30-
> In case you want to start a new L1, you can remove the data of the old one by executing:
31-
>
32-
> ```sh
33-
> ethrex removedb
34-
> ```
13+
For instructions on how to get started using ethrex L1 and/or L2, please refer to the ["Getting started" section of the docs](https://docs.ethrex.xyz/getting-started/index.html).
3514

3615
## L1 and L2 support
3716

docs/SUMMARY.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
# Summary
22

33
- [Getting started](./getting-started/README.md)
4-
- [Installing ethrex]()
5-
- [Build from source]()
6-
- [Running a node]()
4+
- [Installing ethrex](./getting-started/installing.md)
5+
- [Running a node](./getting-started/running.md)
76
- [Migrating from another client]()
87

98
- [Roadmap](./getting-started/roadmap.md)

docs/getting-started/README.md

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,15 @@
11
# Getting started
22

3-
## L1 and L2 support
4-
5-
This client supports running in two different modes:
3+
Ethrex is a minimalist, stable, modular and fast implementation of the Ethereum protocol in [Rust](https://www.rust-lang.org/).
4+
The client supports running in two different modes:
65

76
- As a regular Ethereum execution client
87
- As a multi-prover ZK-Rollup (supporting SP1, RISC Zero and TEEs), where block execution is proven and the proof sent to an L1 network for verification, thus inheriting the L1's security. Support for based sequencing is currently in the works.
98

109
We call the first one "ethrex L1" and the second one "ethrex L2".
1110
You can find more information on our [L1](../l1) or [L2](../l2) docs, respectively.
11+
12+
## Where to start
13+
14+
To get started with ethrex, you can follow the [installation guide](./installing.md) to set up the client on your machine.
15+
Then, a good next step would be to [run a local node](./running.md) and see ethrex in action.

docs/getting-started/installing.md

Lines changed: 112 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,112 @@
1+
# Installing ethrex
2+
3+
Before [running the ethrex client](./running.md), you need to install it.
4+
We have multiple ways to install, depending on your needs.
5+
6+
Pre-built binaries for Linux and macOS are available for each release.
7+
See [Installing from pre-built binaries](#installing-from-pre-built-binaries) for installation instructions.
8+
9+
You can also [install through cargo install](#installing-through-cargo-install), or [build the client from source](#building-from-source).
10+
11+
## Installing from pre-built binaries
12+
13+
To install ethrex from pre-built binaries, first download the binaries for your platform from the [release page](https://github.com/lambdaclass/ethrex/releases).
14+
You can also download it from the command line using `curl` or `wget`:
15+
16+
```sh
17+
# For Linux x86_64
18+
curl -L https://github.com/lambdaclass/ethrex/releases/latest/download/ethrex-linux_x86_64 -o ethrex
19+
wget https://github.com/lambdaclass/ethrex/releases/latest/download/ethrex-linux_x86_64 -O ethrex
20+
21+
# For Linux ARM
22+
curl -L https://github.com/lambdaclass/ethrex/releases/latest/download/ethrex-linux_aarch64 -o ethrex
23+
wget https://github.com/lambdaclass/ethrex/releases/latest/download/ethrex-linux_aarch64 -O ethrex
24+
25+
# For MacOS
26+
curl -L https://github.com/lambdaclass/ethrex/releases/latest/download/ethrex-macos_aarch64 -o ethrex
27+
wget https://github.com/lambdaclass/ethrex/releases/latest/download/ethrex-macos_aarch64 -O ethrex
28+
```
29+
30+
And set the execution bit:
31+
32+
```sh
33+
chmod +x ethrex
34+
```
35+
36+
After that, you can verify the program is working by running:
37+
38+
```sh
39+
./ethrex --version
40+
```
41+
42+
This should output something like:
43+
44+
```text
45+
ethrex ethrex/v0.1.0-HEAD-23191af/aarch64-apple-darwin/rustc-v1.87.0
46+
```
47+
48+
> [!TIP]
49+
> For convenience, you can move the `ethrex` binary to a directory in your `PATH`, so you can run it from anywhere.
50+
51+
After installing the client, see ["Running the client"](./running.md) for instructions on how to use it to run L1 and/or L2 networks.
52+
53+
## Installing through `cargo install`
54+
55+
To install the client, [first install Rust](https://www.rust-lang.org/tools/install) and then run:
56+
57+
```sh
58+
cargo install --locked ethrex \
59+
--git https://github.com/lambdaclass/ethrex.git \
60+
--tag v0.0.2-rc.1 \
61+
--features dev
62+
```
63+
64+
This installs the `ethrex` binary.
65+
For more information on how it is built and installed, see [the cargo-install documentation](https://doc.rust-lang.org/cargo/commands/cargo-install.html).
66+
67+
After that, you can verify the program is working by running:
68+
69+
```sh
70+
ethrex --version
71+
```
72+
73+
This should output something like:
74+
75+
```text
76+
ethrex ethrex/v0.1.0-HEAD-23191af/aarch64-apple-darwin/rustc-v1.87.0
77+
```
78+
79+
After installing the client, see ["Running the client"](./running.md) for instructions on how to use it to run L1 and/or L2 networks.
80+
81+
## Building from source
82+
83+
This section assumes you already have [Rust's `cargo`](https://www.rust-lang.org/tools/install) and [`git`](https://git-scm.com/book/en/v2/Getting-Started-Installing-Git) installed.
84+
85+
You can download the source code of a release from the [GitHub releases page](https://github.com/lambdaclass/ethrex/releases), or by cloning the repository at that version:
86+
87+
```sh
88+
git clone --branch <LATEST_VERSION_HERE> --depth 1 https://github.com/lambdaclass/ethrex.git
89+
```
90+
91+
After that, you can run the following command inside the cloned repo to build the client:
92+
93+
```sh
94+
cargo build --bin ethrex --release --features dev
95+
```
96+
97+
You can find the built binary inside `target/release` directory:
98+
99+
```sh
100+
./target/release/ethrex --version
101+
```
102+
103+
This should output something like:
104+
105+
```text
106+
ethrex ethrex/v0.1.0-HEAD-23191af/aarch64-apple-darwin/rustc-v1.87.0
107+
```
108+
109+
> [!TIP]
110+
> For convenience, you can move the `ethrex` binary to a directory in your `PATH`, so you can run it from anywhere.
111+
112+
After installing the client, see ["Running the client"](./running.md) for instructions on how to use it to run L1 and/or L2 networks.

docs/getting-started/running.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# Running a node
2+
3+
This guide will help you start a local L1+L2 stack using ethrex.
4+
It is assumed that you have already [installed ethrex](./installing.md).
5+
6+
Running `ethrex --help` will display the help message.
7+
8+
## Running an L1 dev environment
9+
10+
After [installing ethrex](./installing.md), you can start a local L1 by running:
11+
12+
```sh
13+
ethrex --dev
14+
```
15+
16+
> [!TIP]
17+
> In case you want to start a new L1, you can remove the data of the old one by executing:
18+
>
19+
> ```sh
20+
> ethrex removedb
21+
> ```

install.sh

Lines changed: 0 additions & 12 deletions
This file was deleted.

0 commit comments

Comments
 (0)