# Configure a node

Select a chain:

```
export CHAINID=empe-testnet-2
export MONIKER=<your moniker> 
```

Init chain and delete generated genesis:

```
emped init $MONIKER --chain-id $CHAINID
rm -rf ~/.empe-chain/config/genesis.json
```

Clone repository with chains

<pre><code>git clone https://github.com/empe-io/empe-chains.git
<strong>cd empe-chains/testnet-2/   
</strong></code></pre>

Copy genesis file from repo:

<pre><code><strong>cp genesis.json ~/.empe-chain/config/
</strong></code></pre>

Change the persistent peers inside `config.toml` file

```
sed -e "s|persistent_peers = \".*\"|persistent_peers = \"$(cat .data | grep -oP 'Persistent peers\s+\K\S+')\"|g" ~/.empe-chain/config/config.toml > ~/.empe-chain/config/config.toml.tmp
mv ~/.empe-chain/config/config.toml.tmp  ~/.empe-chain/config/config.toml
```

Set minimum gas price in `app.toml` file

```
sed -e "s|minimum-gas-prices = \".*\"|minimum-gas-prices = \"$(cat .data | grep -oP 'Minimum Gas Price\s+\K\S+')\"|g" ~/.empe-chain/config/app.toml > ~/.empe-chain/config/app.toml.tmp
mv ~/.empe-chain/config/app.toml.tmp  ~/.empe-chain/config/app.toml
```

Change `external_address` value to contact your node using public ip of your node:

```
PUB_IP=`curl -s -4 icanhazip.com`
sed -e "s|external_address = \".*\"|external_address = \"$PUB_IP:26656\"|g" ~/.empe-chain/config/config.toml > ~/.empe-chain/config/config.toml.tmp
mv ~/.empe-chain/config/config.toml.tmp  ~/.empe-chain/config/config.toml
```

Remember to install wasmvm library as described in the [install wasmvm](/empe-blockchain/overview/install-wasmvm-library.md) to avoid issues with wasm smart contracts.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.empe.io/empe-blockchain/overview/configure-a-node.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
