Skip to content
Snippets Groups Projects
Commit cb4e2f8828a4 authored by Georges Racinet's avatar Georges Racinet
Browse files

launch: new `--root-password` option

This is more convenient than picking the temporary password from
`/etc/gitlab`, and can help reproducing CI failures, since the
environment variable is used in `heptapod-tests` CI.
parent 4c6c3044282b
No related branches found
No related tags found
No related merge requests found
Pipeline #67456 passed
......@@ -121,6 +121,9 @@
run_group.add_argument('--ssh-port', type=int, default=2022)
run_group.add_argument('--container-name', default='heptapod')
run_group.add_argument('--podman', action="store_true")
run_group.add_argument('--root-password',
help="Force the value of root password in "
"the Heptapod instance")
img_group = parser.add_argument_group("Docker image options")
img_group.add_argument('--image-tag',
......@@ -174,6 +177,11 @@
)
for bm in bind_mounts:
run_cmd.extend(('--volume', '%s:%s' % bm))
root_pwd = parsed_args.root_password
if root_pwd:
run_cmd.extend(('--env', f'GITLAB_ROOT_PASSWORD={root_pwd}'))
run_cmd.append(f'{parsed_args.image_repo}:{run_image_tag}')
print("%s run command: %r" % (docker.capitalize(), run_cmd))
if not simulate:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment