Skip to content
Snippets Groups Projects
Commit ba464de9 authored by Karel van Klink's avatar Karel van Klink :smiley_cat:
Browse files

tune some imports, limit port number to non-dynamic range

parent 60b046a9
No related branches found
No related tags found
1 merge request!64new IP trunk migration
Pipeline #84025 passed
This commit is part of merge request !64. Comments created here will be created in the context of that merge request.
from orchestrator.db.models import ProductTable, SubscriptionTable
from orchestrator.forms import FormPage from orchestrator.forms import FormPage
from orchestrator.forms.validators import Choice, UniqueConstrainedList from orchestrator.forms.validators import Choice, UniqueConstrainedList
from orchestrator.targets import Target from orchestrator.targets import Target
......
...@@ -13,8 +13,8 @@ from gso.products.product_blocks import router as router_pb ...@@ -13,8 +13,8 @@ from gso.products.product_blocks import router as router_pb
from gso.products.product_blocks.router import RouterRole, RouterVendor from gso.products.product_blocks.router import RouterRole, RouterVendor
from gso.products.product_types import router from gso.products.product_types import router
from gso.products.product_types.router import RouterInactive from gso.products.product_types.router import RouterInactive
from gso.products.shared import PortNumber
from gso.products.product_types.site import Site from gso.products.product_types.site import Site
from gso.products.shared import PortNumber
from gso.schemas.enums import ProductType from gso.schemas.enums import ProductType
from gso.services import subscriptions from gso.services import subscriptions
from gso.services.crm import get_customer_by_name from gso.services.crm import get_customer_by_name
......
...@@ -87,7 +87,7 @@ def router_subscription_factory(site_subscription_factory, faker): ...@@ -87,7 +87,7 @@ def router_subscription_factory(site_subscription_factory, faker):
) -> UUIDstr: ) -> UUIDstr:
description = description or faker.text(max_nb_chars=30) description = description or faker.text(max_nb_chars=30)
router_fqdn = router_fqdn or faker.domain_name() router_fqdn = router_fqdn or faker.domain_name()
router_ts_port = router_ts_port or faker.random_int(min=1, max=65535) router_ts_port = router_ts_port or faker.random_int(min=1, max=49151)
router_access_via_ts = router_access_via_ts or faker.boolean() router_access_via_ts = router_access_via_ts or faker.boolean()
router_lo_ipv4_address = router_lo_ipv4_address or ipaddress.IPv4Address(faker.ipv4()) router_lo_ipv4_address = router_lo_ipv4_address or ipaddress.IPv4Address(faker.ipv4())
router_lo_ipv6_address = router_lo_ipv6_address or ipaddress.IPv6Address(faker.ipv6()) router_lo_ipv6_address = router_lo_ipv6_address or ipaddress.IPv6Address(faker.ipv6())
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment