Skip to content

Allow passing args to docker user_script#5359

Merged
morgando merged 1 commit intobloomberg:mainfrom
morgando:docker_args
Aug 22, 2025
Merged

Allow passing args to docker user_script#5359
morgando merged 1 commit intobloomberg:mainfrom
morgando:docker_args

Conversation

@morgando
Copy link
Copy Markdown
Contributor

@morgando morgando commented Aug 22, 2025

user_script is the entrypoint that kicks off our testing logic inside Docker test clusters.

This change allows passing arguments to user_script. Existing usage remains unchanged, but optional arguments let us customize behavior when needed.

This prevents us from having to duplicate test scripts when we only need small variations in behavior.

Testing

Using

$ cat test_script.sh
#!/bin/bash

echo "Hi I was passed args '$@'"
  1. Test with multiple arguments
$ comdb2/tests/docker/runit -s comdb2 -n 3 -a 0 -f test_script.sh --file-arg --my-opt --file-arg 1
...
c1        | READY
c1        | Hi I was passed args '0 --my-opt 1'
  1. Test with no arguments
$ comdb2/tests/docker/runit -s comdb2 -n 3 -a 0 -f test_script.sh --file-arg --my-opt --file-arg 1
...
c1        | READY
c1        | Hi I was passed args ''

Signed-off-by: mdouglas47 <mdouglas47@bloomberg.net>
@morgando morgando marked this pull request as ready for review August 22, 2025 16:08
Copy link
Copy Markdown

@roborivers roborivers left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Coding style check: Success ✓.
Smoke testing: Error ⚠.
Cbuild submission: Success ✓.
Regression testing: 1/626 tests failed ⚠.

The first 10 failing tests are:
sc_downgrade

@morgando morgando merged commit 63fd027 into bloomberg:main Aug 22, 2025
4 checks passed
@morgando morgando deleted the docker_args branch August 22, 2025 18:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants