summaryrefslogtreecommitdiff
path: root/python
diff options
context:
space:
mode:
authorJohn Estabrook <jestabro@vyos.io>2024-02-17 15:12:13 -0600
committerGitHub <noreply@github.com>2024-02-17 15:12:13 -0600
commit85e3866dde344b6f829ad38ef09522f1430725dc (patch)
tree9e182ef7df000978220dfcee1fabe2f2c4a4ffcf /python
parentaf2b0f7504f25f9ac3cbefe5e9b5e25de48dd10d (diff)
parent64e8ae09386fc9f311a9309ffab805abd3848ce1 (diff)
downloadvyos-1x-85e3866dde344b6f829ad38ef09522f1430725dc.tar.gz
vyos-1x-85e3866dde344b6f829ad38ef09522f1430725dc.zip
Merge pull request #3025 from vyos/mergify/bp/sagitta/pr-3024
image-tools: T6041: fix logic of is_live_boot to allow for PXE boot (backport #3024)
Diffstat (limited to 'python')
-rw-r--r--python/vyos/system/image.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/python/vyos/system/image.py b/python/vyos/system/image.py
index 5460e6a36..ba9a6dfa7 100644
--- a/python/vyos/system/image.py
+++ b/python/vyos/system/image.py
@@ -259,9 +259,9 @@ def is_live_boot() -> bool:
running_image_result = regex_filter.match(cmdline)
if running_image_result:
boot_type: str = running_image_result.groupdict().get('boot_type', '')
- if boot_type == 'live':
- return True
- return False
+ if boot_type == 'boot':
+ return False
+ return True
def if_not_live_boot(func):
"""Decorator to call function only if not live boot"""