# Install

## Install docker & docker compose&#x20;

{% content-ref url="/pages/nQUeejubm2fRkJ4F6CD2" %}
[Các công cụ cần thiết](/newbie/cac-cong-cu-can-thiet.md)
{% endcontent-ref %}

## Clone the repository against the testnet branch.

```
git clone https://github.com/PowerLoom/deploy.git --single-branch powerloom_testnet_5_pairs --branch testnet_5_pairs && cd powerloom_testnet_5_pairs
```

## Copy `env.example` to `.env`

```
cp env.example .env
```

## Edit the .env file

```
nano .env
```

Ensure the following required variables are filled:

* SOURCE\_RPC\_URL: The URL for Ethereum RPC (Local node/Infura/Alchemy) service.
* SIGNER\_ACCOUNT\_ADDRESS: The address of the signer account. This is your whitelisted address on testnet - please file a ticket if you need a new burner wallet registered.
* SIGNER\_ACCOUNT\_PRIVATE\_KEY: The private key corresponding to the signer account address.

## Create SystemD

```
sudo tee /etc/systemd/system/powerloom.service > /dev/null <<EOF
[Unit]
Description=Powerloom snapshot
After=network-online.target

[Service]
User=$USER
WorkingDirectory=$HOME
ExecStart=$HOME/powerloom_testnet_5_pairs/build.sh
Restart=on-failure
RestartSec=5
LimitNOFILE=65535

[Install]
WantedBy=multi-user.target
EOF
```

```
sudo systemctl daemon-reload
sudo systemctl enable powerloom.service
```

## Start service

```
sudo systemctl start powerloom.service && journalctl -u powerloom -f
```

## Stop service

```
sudo systemctl stop powerloom.service && journalctl -u powerloom -f
```

## Check logs

```
docker ps
```

if all the necessary docker containers are up and running. You should see an output against:

```
# docker ps

CONTAINER ID   IMAGE                                  COMMAND                  CREATED       STATUS                 PORTS                                                                                                                                                 NAMES
bfa1abe2b8aa   powerloom-pooler-frontend              "sh -c 'sh snapshott…"   2 hours ago   Up 2 hours (healthy)   0.0.0.0:3000->3000/tcp, :::3000->3000/tcp                                                                                                             deploy-pooler-frontend-1
852f3445f11c   powerloom-pooler                       "bash -c 'sh init_pr…"   2 hours ago   Up 2 hours (healthy)   0.0.0.0:8002->8002/tcp, :::8002->8002/tcp, 0.0.0.0:8555->8555/tcp, :::8555->8555/tcp                                                                  deploy-pooler-1
ee652fda8513   powerloom-audit-protocol               "bash -c 'sh init_pr…"   2 hours ago   Up 2 hours (healthy)   0.0.0.0:9000->9000/tcp, :::9000->9000/tcp, 0.0.0.0:9002->9002/tcp, :::9002->9002/tcp                                                                  deploy-audit-protocol-1
5547fb5c1ab4   ipfs/kubo:release                      "/sbin/tini -- /usr/…"   2 hours ago   Up 2 hours (healthy)   4001/tcp, 8080-8081/tcp, 4001/udp, 0.0.0.0:5001->5001/tcp, :::5001->5001/tcp                                                                          deploy-ipfs-1
999de5864a1b   rabbitmq:3-management                  "docker-entrypoint.s…"   2 hours ago   Up 2 hours (healthy)   4369/tcp, 5671/tcp, 0.0.0.0:5672->5672/tcp, :::5672->5672/tcp, 15671/tcp, 15691-15692/tcp, 25672/tcp, 0.0.0.0:15672->15672/tcp, :::15672->15672/tcp   deploy-rabbitmq-1
2c14926d7cfd   redis                                  "docker-entrypoint.s…"   2 hours ago   Up 2 hours (healthy)   0.0.0.0:6379->6379/tcp, :::6379->6379/tcp                                                                                                             deploy-redis-1
```


---

# 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.mewcrypto.com/testnet/powerloom/install.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.
