Skip to content

Commit 427accb

Browse files
committed
Rename 'args' to 'buildah_extra_args'
Signed-off-by: Trey Dockendorf <tdockendorf@osc.edu>
1 parent ea081c0 commit 427accb

2 files changed

Lines changed: 7 additions & 7 deletions

File tree

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -140,9 +140,9 @@ packages:
140140
# control command verbosity. By default, it is 'INFO'.
141141
cmds:
142142
- cmd: 'echo hello'
143-
# 'cmd' also supports 'args' that are passed to 'buildah run'
143+
# 'cmd' also supports 'buildah_extra_args' that are passed to 'buildah run'
144144
- cmd: 'id user'
145-
args: ['--volume', '/var/lib/sss:/var/lib/sss:z']
145+
buildah_extra_args: ['--volume', '/var/lib/sss:/var/lib/sss:z']
146146

147147
# OpenSCAP options to use with scap_benchmark or oval_eval. Each OpenSCAP
148148
# command gets passed to the shell. By default, the results from OpenSCAP will be saved

src/installer.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -215,10 +215,10 @@ def install_base_commands(self, commands):
215215
logging.info(f"COMMANDS: running these commands in {self.cname}")
216216
for c in commands:
217217
logging.info(c['cmd'])
218-
args = []
219-
if 'args' in c:
220-
args.extend(c['args'])
221-
args.extend([self.cname, '--', 'bash', '-c', c['cmd']])
218+
build_cmd = ["buildah","run"]
219+
if 'buildah_extra_args' in c:
220+
build_cmd.extend(c['buildah_extra_args'])
221+
args = [self.cname, '--', 'bash', '-c', c['cmd']]
222222
if 'loglevel' in c:
223223
if c['loglevel'].upper() == "INFO":
224224
loglevel = logging.info
@@ -228,7 +228,7 @@ def install_base_commands(self, commands):
228228
loglevel = logging.error
229229
else:
230230
loglevel = logging.error
231-
out = cmd(["buildah","run"] + args, stderr_handler=loglevel)
231+
out = cmd(build_cmd + args, stderr_handler=loglevel)
232232

233233
def install_base_copyfiles(self, copyfiles):
234234
if len(copyfiles) == 0:

0 commit comments

Comments
 (0)