rcstack cli test-traffic¶
runs a traffic test against the current rhodecode instance
Usage¶
rcstack cli test-traffic [OPTIONS]
By default this command keeps the existing HTTP ping behavior.
Git-over-SSH checks are enabled only when --ssh-repo-url is provided.
The SSH smoke test performs a real Git workflow over SSH:
clone the repository;
create a temporary branch;
commit a marker file;
push the branch;
clone the branch again and verify the marker file;
delete the temporary branch unless
--ssh-keep-branchis used.
Use a disposable test repository or a repository where the selected SSH key is allowed to create and delete temporary branches.
Example:
rcstack cli test-traffic \
--ssh-repo-url ssh://rhodecode@127.0.0.1:9022/smoke-test.git \
--ssh-identity-file ./config/_shared/ssh/id_rsa \
--ssh-container rc_cluster_apps-sshd-1
Stress example:
rcstack cli test-traffic \
--ssh-repo-url ssh://rhodecode@127.0.0.1:9022/smoke-test.git \
--ssh-identity-file ./config/_shared/ssh/id_rsa \
--ssh-container rc_cluster_apps-sshd-1 \
--ssh-stress \
--ssh-concurrency 16 \
--ssh-duration 120 \
--ssh-command-timeout 180
Options¶
–verbose¶
rich output about image
–test-url TEST_URL¶
sub path url to test
Attributes |
|
|---|---|
Default Value: |
http://127.0.0.1/_admin/ops/ping |
–ssh-repo-url SSH_REPO_URL¶
Git-over-SSH repository URL to smoke test.
–ssh-identity-file SSH_IDENTITY_FILE¶
SSH private key used by Git-over-SSH tests. If omitted, Git uses the local SSH agent/config.
–ssh-container SSH_CONTAINER¶
Optional sshd container name for leftover rc-ssh-wrapper-v2 process checks.
When provided, the command compares wrapper process count before and after the SSH test and fails if the count increased.
–ssh-branch-prefix SSH_BRANCH_PREFIX¶
Temporary branch prefix used by Git-over-SSH push smoke tests.
Attributes |
|
|---|---|
Default Value: |
rcstack-ssh-smoke |
–ssh-stress¶
Run a parallel Git-over-SSH clone/fetch stress test after the smoke test.
–ssh-concurrency SSH_CONCURRENCY¶
Number of parallel workers for --ssh-stress.
Attributes |
|
|---|---|
Default Value: |
8 |
–ssh-duration SSH_DURATION¶
Stress test duration in seconds for --ssh-stress.
Attributes |
|
|---|---|
Default Value: |
60 |
–ssh-command-timeout SSH_COMMAND_TIMEOUT¶
Timeout in seconds for each Git-over-SSH command. Use 0 to disable the timeout.
Attributes |
|
|---|---|
Default Value: |
120 |
–ssh-keep-branch¶
Keep the temporary pushed smoke-test branch instead of deleting it.
–http-only¶
Run only the HTTP traffic check even when SSH options are present.
–ssh-only¶
Run only the Git-over-SSH traffic check and skip the HTTP ping.