I know you can add a network to brownie by using a command:
brownie networks add Ethereum ganache-local host=http://127.0.0.1:7545 chainid=5777
or for example:
brownie networks add development ganache-local host=http://127.0.0.1:7545 cmd=ganache
In both cases, I get a network named
ganache-local that is connected to my ganache GUI and therefore I can deploy my smart contracts and do testing there.
However, what I want, is to know how to add network into
brownie-confing.yaml file and have it work all the same. (As I am well used to doing that inside truffle-config.js)
I tried it in a few ways, but nothing worked so far.
Here is my brownie-config.yaml. Hopefully, someone can tell me what I am doing wrong. (I am trying to add a network named
local that has the same parameters as the
ganache-local from the commands listed above.
networks: local: # the default network that brownie connects to host: "127.0.0.1" port: 7545 chainid: 5777 network_id: "*" cmd: ganache compiler: solc: remappings: - "@openzeppelin=OpenZeppelin/[email protected]"
Whenever I try running:
brownie run deploy.py --network local
I get an error: