Skip to content

Commit

Permalink
add_upgrade_boot: rename variables
Browse files Browse the repository at this point in the history
  • Loading branch information
Michal Hecko committed Aug 13, 2024
1 parent a2e76b9 commit 967af6b
Showing 1 changed file with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -287,18 +287,18 @@ def construct_cmdline_args_for_livemode():
if not livemode_artifacts:
raise StopActorExecutionError('Did not receive any livemode artifacts message although it is enabled.')

liveimg = os.path.basename(livemode_artifacts.squashfs_path)
livedir = os.path.dirname(livemode_artifacts.squashfs_path)
liveimg_filename = os.path.basename(livemode_artifacts.squashfs_path)
dir_path_containing_liveimg = os.path.dirname(livemode_artifacts.squashfs_path)

args = {'rw': None}

# if an URL is defined, boot over the network (http, nfs, ftp, ...)
if livemode_config.url_to_load_squashfs_from:
args['root'] = 'live:{}'.format(livemode_config.url_to_load_squashfs_from)
else:
args['root'] = 'live:UUID={}'.format(_get_device_uuid(livedir))
args['rd.live.dir'] = livedir
args['rd.live.squashimg'] = liveimg
args['root'] = 'live:UUID={}'.format(_get_device_uuid(dir_path_containing_liveimg))
args['rd.live.dir'] = dir_path_containing_liveimg
args['rd.live.squashimg'] = liveimg_filename

if livemode_config.dracut_network:
network_fragments = livemode_config.dracut_network.split('=', maxsplit=1)
Expand Down

0 comments on commit 967af6b

Please sign in to comment.