From 685488e25808cff62ab3e7a32860e8494203d49e Mon Sep 17 00:00:00 2001 From: Nicolas Iselin Date: Tue, 1 Aug 2023 18:32:47 +0200 Subject: [PATCH] fix: make wired configs work again --- container/autoinstall-user-data.j2 | 2 +- container/build-iso.py | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/container/autoinstall-user-data.j2 b/container/autoinstall-user-data.j2 index aae9338..a7c1248 100644 --- a/container/autoinstall-user-data.j2 +++ b/container/autoinstall-user-data.j2 @@ -10,7 +10,7 @@ autoinstall: hostname: {{ config['initial_hostname'] | default('potoshostname01') }} password: {{ config['initial_user']['password'] | default('$6$L36BiUuVCSipvlO8$oGI0C.LXZegkbftFkVDXXaasTM6zs9LM71BkqZToKw5aOZ7Yr70pkzH3P9Xz5R.n0ULJ0Zf8v5ZQ/eH8flDR7/') }} username: {{ config['initial_user']['username'] | default('admin') }} -{% if config['wifi']['ssid'] is defined %} +{% if config['wifi']['interface'] is defined and config['wifi']['interface'] != None %} early-commands: - apt-get -y install wpasupplicant drivers: diff --git a/container/build-iso.py b/container/build-iso.py index 5eb8999..9f3dd7f 100755 --- a/container/build-iso.py +++ b/container/build-iso.py @@ -35,9 +35,9 @@ config['initial_user']['username'] = ymlconfig.get("initial_user",{}).get('username',"admin") config['initial_user']['password'] = ymlconfig.get("initial_user",{}).get('password',"$6$L36BiUuVCSipvlO8$oGI0C.LXZegkbftFkVDXXaasTM6zs9LM71BkqZToKw5aOZ7Yr70pkzH3P9Xz5R.n0ULJ0Zf8v5ZQ/eH8flDR7/") config['wifi'] = {} - config['wifi']['interface'] = ymlconfig.get("wifi",{}).get('interface',"wlan0") - config['wifi']['ssid'] = ymlconfig.get("wifi",{}).get('ssid',"yourwifissid") - config['wifi']['pw'] = ymlconfig.get("wifi",{}).get('pw',"yourwifipassword") + config['wifi']['interface'] = ymlconfig.get("wifi",{}).get('interface') + config['wifi']['ssid'] = ymlconfig.get("wifi",{}).get('ssid') + config['wifi']['pw'] = ymlconfig.get("wifi",{}).get('pw') config['environment'] = ymlconfig.get("environment","production") config['first_boot_ansible'] = {} config['first_boot_ansible']['runtype'] = ymlconfig.get("first_boot_ansible",{}).get('runtype',"setup")