feat: add STORAGE_SKIP_SSL_VERIFICATION for copy-offload#445
feat: add STORAGE_SKIP_SSL_VERIFICATION for copy-offload#445rgolangh wants to merge 2 commits intoRedHatQE:mainfrom
Conversation
|
Report bugs in Issues Welcome! 🎉This pull request will be automatically processed with the following features: 🔄 Automatic Actions
📋 Available CommandsPR Status Management
Review & Approval
Testing & Validation
Container Operations
Cherry-pick Operations
Label Management
✅ Merge RequirementsThis PR will be automatically approved when the following conditions are met:
📊 Review ProcessApprovers and ReviewersApprovers:
Reviewers:
Available Labels
AI Features
💡 Tips
For more information, please refer to the project documentation or contact the maintainers. |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Run ID: 📒 Files selected for processing (1)
WalkthroughAdds optional skip-SSL-verification for copy-offload storage: an example ChangesCopy-offload storage: add optional skip-SSL verification
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Tip 💬 Introducing Slack Agent: The best way for teams to turn conversations into code.Slack Agent is built on CodeRabbit's deep understanding of your code, so your team can collaborate across the entire SDLC without losing context.
Built for teams:
One agent for your entire SDLC. Right inside Slack. Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@tests/copyoffload/conftest.py`:
- Around line 183-186: The current truthy check on skip_ssl (value from
get_copyoffload_credential) treats any non-empty string like "false" as enabled;
update the branch that sets secret_data["STORAGE_SKIP_SSL_VERIFICATION"] to
explicitly parse/normalize the string instead of relying on Python truthiness —
e.g., call or mirror the project's SSL parsing logic used in
_get_ssl_config/generate.py (normalize to lower() and compare against
("true","1","yes") or reuse _get_ssl_config) and only set the secret when the
parsed boolean is True, leaving it unset for "false"/"0"/"no".
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro
Run ID: b3d1235f-6991-4b85-94dc-442708580e3d
📒 Files selected for processing (8)
.providers.json.examplecli/mtv_api_tests/common.pycli/mtv_api_tests/generate.pydocs/container-and-openshift-job-execution.mddocs/copy-offload-migrations.mddocs/installation-and-local-setup.mddocs/optional-integrations-and-secrets.mdtests/copyoffload/conftest.py
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@tests/copyoffload/conftest.py`:
- Around line 183-187: The fixture normalizes skip_ssl with skip_ssl.lower()
which misses leading/trailing whitespace and is inconsistent with
cli/mtv_api_tests/common.py::_get_ssl_config; update the handling where skip_ssl
is obtained via get_copyoffload_credential so you call .strip().lower() (e.g.,
normalize skip_ssl = get_copyoffload_credential(...); if skip_ssl and
skip_ssl.strip().lower() in ("true","1","yes") then set
secret_data["STORAGE_SKIP_SSL_VERIFICATION"]="true") to match _get_ssl_config
and avoid false negatives from values like " true\n".
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro
Run ID: 733c247c-7697-433b-99a1-fc4581dd2c60
📒 Files selected for processing (1)
tests/copyoffload/conftest.py
…age secrets Allow skipping SSL certificate verification for storage array connections in copy-offload tests, configurable via providers.json or env var. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
61de275 to
4d37e60
Compare
|
Clean rebase detected — no code changes compared to previous head ( |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@tests/copyoffload/conftest.py`:
- Around line 183-186: The code calls .lower() on skip_ssl (value from
get_copyoffload_credential) which may be a non-string (e.g., bool) and crash;
change the guard to ensure skip_ssl is a string before calling .lower() — e.g.,
check isinstance(skip_ssl, str) and then compare skip_ssl.lower() in
("true","1","yes") or coerce via str(skip_ssl).lower(); update the block that
sets secret_data["STORAGE_SKIP_SSL_VERIFICATION"] accordingly and keep using the
same symbols skip_ssl, get_copyoffload_credential, secret_data, and
STORAGE_SKIP_SSL_VERIFICATION to locate the change.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro
Run ID: 0a1fd2bc-9287-4ffe-9d83-4a1cfb5c2f78
📒 Files selected for processing (8)
.providers.json.examplecli/mtv_api_tests/common.pycli/mtv_api_tests/generate.pydocs/container-and-openshift-job-execution.mddocs/copy-offload-migrations.mddocs/installation-and-local-setup.mddocs/optional-integrations-and-secrets.mdtests/copyoffload/conftest.py
…ation Coerce skip_ssl via str() before calling .lower() to handle JSON booleans from dict[str, Any], and add .strip() for parity with _get_ssl_config. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
@coderabbitai review |
✅ Actions performedReview triggered.
|
Summary
STORAGE_SKIP_SSL_VERIFICATIONfield to the copy-offload storage secret, configurable via.providers.json(storage_skip_ssl_verification) or env var (COPYOFFLOAD_STORAGE_SKIP_SSL_VERIFICATION)get_storage_credentials()with SSL config (reuses existing_get_ssl_config("STORAGE")pattern), writingstorage_skip_ssl_verification: "true"into the generated config when SSL verification is disabled.providers.json.exampleto document the new optionTest plan
COPYOFFLOAD_STORAGE_SKIP_SSL_VERIFICATION=trueand verify the storage secret includes theSTORAGE_SKIP_SSL_VERIFICATIONkeygenerateflow withSTORAGE_VERIFY_SSL=falseand confirmstorage_skip_ssl_verification: "true"appears in the generated.providers.json🤖 Generated with Claude Code
Summary by CodeRabbit
New Features
Documentation
Tests
Chores