# Node Setup

#### Requirements: <a href="#requirements" id="requirements"></a>

* Docker and Docker Compose.
* Ubuntu / Ubuntu-like server

**Setup docker and docker-compose:**

Copy

```
sudo apt update; sudo apt install docker.io -y
sudo usermod -aG docker $USER
mkdir -p ~/.docker/cli-plugins/
sudo curl -L "https://github.com/docker/compose/releases/latest/download/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose; sudo chmod +x /usr/local/bin/docker-compose
sudo usermod -aG docker $USER; newgrp docker
```

**Clone Metacces RPC node repo:**

`git clone(Will update with Metacces repo)`

`cd rpcnode`

You may need to give permissions to sh files. To do so, run:

`chmod +x *.sh`

Then run:

`./run.sh`

The docker-compose.yml file includes all the needed information.

You can adjust some variables if you are familiar with that.

**## Additional commands:**

./stop.sh: stops the node keeping its data.

./resume.sh: resumes the node, it runs after stop.sh

./restart.sh: restarts the node container

./remove.sh: removes the node data completely

./qlogs.sh: displays the node container logs

./johnwickdocker.sh: destroys all docker related resources, starts clean.

**To test if the node is working:**

1\. Paste your server's IP with port 22000 in a web browser: <http://SERVER\\_IP:22000>

If a blank white page is displayed, your node is working fine. Else, you'll get an error.

2\. In MetaMask network settings, place the address: <http://your-ip:22000> for the RPC URL.

If you connect to the network, it means you are set. But you may need to wait for synchronization to complete.

During synchronization (first hour or so) your wallet balance may not reflect the correct value.

<br>


---

# 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.metacces.com/whitepaper/metacces-general/blockchain-layer-1/developers/node-setup.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.
