Skip to content

Cannot run as Service #688

@mtgnoah

Description

@mtgnoah

I wrote a service file to use ANR to run a local devnet that doesn't get killed when I close my terminal but I cannot add a subnet to it when it's running in the service

Here is the error I get
Error: rpc error: code = Unknown desc = avalanche exec is not defined

Here is the service

[Unit]

Description=Avalanche Network Runner
After=network-online.target
Wants=network-online.target

[Service]

WorkingDirectory=/home/ubuntu
User=ubuntu
ExecStart=/home/ubuntu/code/avalanche-network-runner/bin/avalanche-network-runner server --log-level debug --port=":8080" --grpc-gateway-port=":8081"
Restart=always
RestartSec=5s

[Install]
WantedBy=multi-user.target

Here is the command I am trying to run which gives the error above

avalanche-network-runner control start --log-level debug --endpoint="localhost:8080" --blockchain-specs '[{"vm_name": "tokenvm", "genesis": "/home/ubuntu/code/tests/tokenvm-genesis.json", "chain_config": "/home/ubuntu/code/tests/tokenvm-chain-config.json", "subnet_config": "/home/ubuntu/code/tests/tokenvm-subnet-config.json"}]'

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

Status

Backlog 🧊

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions