Skip to content

Commit

Permalink
added echo and changed network addr
Browse files Browse the repository at this point in the history
  • Loading branch information
HenrithicusGreenson committed Apr 15, 2024
1 parent f23befb commit c271d5c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion genisys/config_parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ def get_section(self: Self, heading: str) -> dict:
dictionary['ip'] = str(IPv4Address(runner_ip) + 1)
# Create (estimated) network/subnet value
octets = runner_ip.split('.')
network_addr = '.'.join([octets[0], '0', '0', '0'])
network_addr = '.'.join([octets[0], octets[1], octets[2], '0'])
dictionary['subnet'] = network_addr + '/24'
# Create (estimated) DHCP range
dictionary['dhcp-ranges'] = network_addr + ',' + str(str(IPv4Address(runner_ip) + 10))
Expand Down
1 change: 1 addition & 0 deletions genisys/server/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ def run(config: YAMLParser):
server_address = network.get('ip', '')
server_port = server_options.get("port", DEFAULT_PORT)
inventory = GenisysInventory(db_uri, db_name, collection_name)
print("Assigning address: ", server_address)
httpd = GenisysHTTPServer((server_address, server_port), inventory, config)
# apply TLS if applicable
if 'ssl' in server_options:
Expand Down

0 comments on commit c271d5c

Please sign in to comment.