Skip to content

Commit

Permalink
chore(docs): operator avs registration (#495)
Browse files Browse the repository at this point in the history
adds docs on registering as an operator on testnet

task: none
  • Loading branch information
idea404 authored Mar 5, 2024
1 parent da8b217 commit 3c8d801
Show file tree
Hide file tree
Showing 9 changed files with 154 additions and 41 deletions.
2 changes: 1 addition & 1 deletion docs/site/docs/home.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,4 @@ slug: /

_Welcome to the documentation portal for all things Omni!_

Please read on to learn [about Omni](./learn/introduction/introduction.md), [the network](./protocol/introduction.md), [developer docs](./develop/contracts.md) and [running a validator](./operate/introduction.md).
Please read on to learn [about Omni](./learn/introduction/introduction.md), [the network](./protocol/introduction.md), [developer docs](./develop/contracts.md) and [running a validator](./operate/introduction/introduction.md).
33 changes: 0 additions & 33 deletions docs/site/docs/operate/introduction.md

This file was deleted.

15 changes: 15 additions & 0 deletions docs/site/docs/operate/introduction/introduction.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
---
sidebar_position: 1
---

# Introduction

## What Is a Node Operator in Omni?

Operators run Omni node software and play an active role in validating the Omni network.

In all other blockchains, validators can only stake the native token of that chain. With Omni, validators can stake **\$OMNI**, but they can also restake **\$ETH**, via Eigenlayer. Operators can also receive **\$ETH** delegations from other users.

## How Do I Become an Operator?

If you'd like to become an Omni operator, please reach out to the team.
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
sidebar_position: 2
---

# Run a Validator
# Validator Requirements

Omniʼs operator needs to run the consensus client and the execution client:

Expand Down
17 changes: 17 additions & 0 deletions docs/site/docs/operate/testnet/client.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
sidebar_position: 4
---

# Run the Client

This is the component that participates in network validation. Our consensus clients track delegations and stake from our AVS contracts.

Similar to Ethereum, Omni validators run 2 components: our consensus client, `halo`, and an EVM execution client `geth`, `erigon`, `nethermind`, etc.

:::info

This feature is not yet enabled. Please do not attempt to run it.

:::

<!-- TODO(dennis): include run commands, preferably with CLI -->
41 changes: 41 additions & 0 deletions docs/site/docs/operate/testnet/install.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
---
sidebar_position: 2
---

# Installing the Omni CLI

The Omni CLI will allow you to interact with the Omni network and simplifies the process of performing actions as an operator.

## Install from Binary

The easiest way to install the Omni CLI is to download the latest release from the [GitHub releases page](https://github.com/omni-network/omni/releases). Once downloaded, you can extract the binary and move it to a location in your PATH.

## Install from Script

You can also install the Omni CLI using the following script:

```bash
curl -sSfL https://raw.githubusercontent.com/omni-network/omni/main/scripts/install_omni_cli.sh | sh -s
```

## Install from Source

import Tabs from '@theme/Tabs';
import TabItem from '@theme/TabItem';

<Tabs>
<TabItem value="source" label="src with make">
```bash
git clone https://github.com/omni-network/omni.git
cd omni
make install-cli
```
</TabItem>
<TabItem value="go" label="src with go">
```bash
git clone https://github.com/omni-network/omni.git
cd omni
go install ./cli/cmd/omni
```
</TabItem>
</Tabs>
11 changes: 11 additions & 0 deletions docs/site/docs/operate/testnet/introduction.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
sidebar_position: 1
---

# EigenLayer Registration

## Registering as an Operator for Testnet

To register with Omni, operators must first register as an operator in Eigenlayer testnet

This registers your Ethereum public key with the Eigenlayer. You can follow Eigenlayer's instructions [here](https://docs.eigenlayer.xyz/eigenlayer/operator-guides/operator-installation).
39 changes: 39 additions & 0 deletions docs/site/docs/operate/testnet/register.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
---
sidebar_position: 3
---

# Omni AVS Contract Registration

This tells EigenLayer that you'd like to be an operator specifically for the Omni AVS. Thus, the **\$ETH** that you, and your delegators restaked, will be used to secure Omni. Omni provides a CLI for this.

You will need to have an `operator.yml` file to perform this registration. This file is created as part of [registering as an operator with the EigenLayer CLI](https://docs.eigenlayer.xyz/eigenlayer/operator-guides/operator-installation).

<details>
<summary>`operator.yml` Reference</summary>

For further information on this reference, please refer to the [EigenLayer reference example](https://github.com/Layr-Labs/eigenlayer-cli/blob/master/pkg/operator/config/operator-config-example.yaml).

```yaml
operator:
address: 0xfd23f7f705344bce1582fcf9bc6a0dc8e33b3b61 # Your operator address
earnings_receiver_address: 0xfd23f7f705344bce1582fcf9bc6a0dc8e33b3b61 # Your operator payout address, may be the same as above
delegation_approver_address: "0x0000000000000000000000000000000000000000" # Your delegation approver address, may be left as shown
staker_opt_out_window_blocks: 0 # may be left as shown, and can be updated later using EigenLayer CLI
metadata_url: "https://raw.githubusercontent.com/idea404/resources/main/eigenlayer/metadata.json" # Your metadata URL
el_delegation_manager_address: 0x8ce361602B935680E8DeC218b820ff5056BeB7af # The address of the EigenLayer delegation manager on the Omni Network
eth_rpc_url: http://127.0.0.1:8002 # Your node Ethereum RPC URL
private_key_store_path: /Users/idea404/.eigenlayer/operator_keys/OpKeys1.ecdsa.key.json # Your private key store path generated or imported by EigenLayer CLI
signer_type: local_keystore # Your signer type, may be left as shown
chain_id: 100 # The chain ID of the Omni Network
```
</details>
## Register as an Operator
1. Ensure that your node address has been added to the allowed list of operators.
2. Run the following command to register as an operator:
```bash
omni operator register --config-file ~/path/to/operator.yml --avs-address <AVS_CONTRACT_ADDRESS>
```
35 changes: 29 additions & 6 deletions docs/site/sidebars.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,7 @@ const sidebars: SidebarsConfig = {
type: "category",
label: "Introduction",
className: "sidebar-title",
collapsible: true,
collapsed: false,
collapsible: false,
items: [
{
type: "autogenerated",
Expand All @@ -23,7 +22,7 @@ const sidebars: SidebarsConfig = {
type: "category",
label: "Background",
className: "sidebar-title",
collapsible: true,
collapsible: false,
items: [
{
type: "autogenerated",
Expand All @@ -39,7 +38,7 @@ const sidebars: SidebarsConfig = {
type: "category",
label: "Omni",
className: "sidebar-title",
collapsible: true,
collapsible: false,
items: [
{
type: "autogenerated",
Expand Down Expand Up @@ -122,9 +121,33 @@ const sidebars: SidebarsConfig = {
],
operateSidebar: [
{
type: "autogenerated",
dirName: "operate",
type: "category",
label: "Introduction",
className: "sidebar-title",
collapsible: false,
items: [
{
type: "autogenerated",
dirName: "operate/introduction",
}
]
},
{
type: "html",
value: "<div class='sidebar-separator'></div>",
},
{
type: "category",
label: "Testnet",
className: "sidebar-title",
collapsible: false,
items: [
{
type: "autogenerated",
dirName: "operate/testnet",
}
]
}
],
};

Expand Down

0 comments on commit 3c8d801

Please sign in to comment.