summaryrefslogtreecommitdiff
path: root/kpov_judge/tasks/isc_dhcp_live_boot
diff options
context:
space:
mode:
authorTimotej Lazar <timotej.lazar@fri.uni-lj.si>2018-10-06 23:56:03 +0200
committerTimotej Lazar <timotej.lazar@fri.uni-lj.si>2018-10-07 01:55:26 +0200
commit9c51bbe5016495c714789f5df01806a6d366e11a (patch)
tree19be73e896838cfbe3e87b04bd63c9fdd930c27e /kpov_judge/tasks/isc_dhcp_live_boot
parente33085889f26c76587fdab2ad600ed336dc028b5 (diff)
Rename kpov_random_helpers to kpov_util
Diffstat (limited to 'kpov_judge/tasks/isc_dhcp_live_boot')
-rw-r--r--kpov_judge/tasks/isc_dhcp_live_boot/task.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/kpov_judge/tasks/isc_dhcp_live_boot/task.py b/kpov_judge/tasks/isc_dhcp_live_boot/task.py
index c5ac728..3004209 100644
--- a/kpov_judge/tasks/isc_dhcp_live_boot/task.py
+++ b/kpov_judge/tasks/isc_dhcp_live_boot/task.py
@@ -2,7 +2,7 @@
# -*- coding: utf-8 -*-
# TODO: dokoncaj!
-# kpov_random_helpers should be imported by add_assignment.py
+# kpov_util should be imported by add_assignment.py
instructions = {
'si':"""
@@ -161,10 +161,10 @@ def task(IP_DHCP, IP_GW, MAC_BOOT, BOOT_FNAME):
def gen_params(user_id, params_meta):
params = dict()
r = random.Random(user_id)
- net = kpov_random_helpers.IPv4_subnet_gen(r, '10.64.0.0/10', 24)
- params['IP_DHCP'], params['IP_GW'] = kpov_random_helpers.IPv4_addr_gen(r, net, 2)
- params['BOOT_FNAME'] = kpov_random_helpers.fname_gen(r)
- params['TFTP_STRING'] = kpov_random_helpers.alnum_gen(r, 45)
+ net = kpov_util.IPv4_subnet_gen(r, '10.64.0.0/10', 24)
+ params['IP_DHCP'], params['IP_GW'] = kpov_util.IPv4_addr_gen(r, net, 2)
+ params['BOOT_FNAME'] = kpov_util.fname_gen(r)
+ params['TFTP_STRING'] = kpov_util.alnum_gen(r, 45)
# IP_NM, DNS_NM, IP_static, DNS_static)
return params