Open ledyba-z opened 4 years ago
This is due to the way that the assignment of IP Address is currently handled. Its alot easier in Python for example to get an available ip address by doing things such as:
import ipaddress
ipnetwork = ipaddress.ip_network("192.168.0.0/24")
gateway = ipaddress.ip_address("192.168.0.1")
client_one = ipaddress.ip_address("192.168.0.2")
client_two = ipaddress.ip_address("192.168.0.10")
used = [gateway, client_one, client_two]
availabe_hosts = [host for host in ipnetwork.hosts() if host not in used]
This always ensures that the first available ip_address
is given to the caller and also ensure that the ip_address
is valid as the library is really smart. I might be able to achieve the same thing in Go, which will mean there can be any number of clients and it will remove the current restriction of:
As the library will be far smarted in mangement of IPAddresses.
@ledyba-z Is this something you would be willing to contribute towards?
Its alot easier in Python for example to get an available ip address by doing things such as:
Golang also equips a standard library to handle IP addrs, so it can be done easily as python.
Is this something you would be willing to contribute towards?
I think I can contribute them. But please wait a little... I am currently so busy and I can't spare the time soon for this issue.
Hey guys! Do we have any possibility to get fix with limits of 254 devices?
Describe the bug
Currently, both entrypoint.sh or handlers.go expects the netmask should be /24 or /112.
https://github.com/subspacecommunity/subspace/blob/master/entrypoint.sh#L45-L53
https://github.com/subspacecommunity/subspace/blob/master/handlers.go#L427
To Reproduce
10.0.10.1
will never assignd. Instead,10.0.0.256/16
is assigned, which is obviously invalid.Expected behavior
10.0.0.2/16
or10.0.10.1/16
.We use subspace in our company, so we really would like to use larger network range.