kwilteam / kwil-db

Kwil DB, the database for web3
https://www.kwil.com/
Other
36 stars 12 forks source link

test: randomized non-overlapping networks on 10.A.B.0/20 #1023

Closed jchappelow closed 1 month ago

jchappelow commented 2 months ago

Since we cannot set Docker's default-address-pools in daemon.json on Github Actions like we did our our old self-hosted running, this PR attempts to pick random /20 networks in 10.A.B.0/20 (there are 4096 subnets each with 4096 addresses) rather than use "10.9.0.0/16", which can cause trouble if the network isn't taken down fast enough or if a test fails and decides not to clean up the network, which can break subsequent tests without different networks.

jchappelow commented 2 months ago

closing, but keeping my branch handing in case CI starts hitting failed to create docker network for TestStatesync/cli_driver: Error response from daemon: Pool overlaps with other one on this address space: failed to create network, or we can remove the IPAM section entirely to go back to docker managed random networks, but it seems that was clashing with github's services networks somehow.

jchappelow commented 1 month ago

Closing but not deleting branch in case we want to resurrect this.

jchappelow commented 1 month ago

I think we should at least try this before entirely reverting the ipam section of docker network config. I'm seeing frequent docker errors in CI related to overlapping networks. Usually it's just following a failed test that is not cleaned up, but it is misleading when trying to diagnose CI failure.