https://github.com/redhatqe/openshift-python-wrapper-data-collector
Data collector for https://github.com/openshift/openshift-python-wrapper when running with PyTest
https://github.com/redhatqe/openshift-python-wrapper-data-collector
Last synced: 8 months ago
JSON representation
Data collector for https://github.com/openshift/openshift-python-wrapper when running with PyTest
- Host: GitHub
- URL: https://github.com/redhatqe/openshift-python-wrapper-data-collector
- Owner: RedHatQE
- License: apache-2.0
- Created: 2023-02-05T12:08:42.000Z (almost 3 years ago)
- Default Branch: main
- Last Pushed: 2025-05-06T11:35:57.000Z (8 months ago)
- Last Synced: 2025-05-06T12:50:57.587Z (8 months ago)
- Language: Python
- Size: 651 KB
- Stars: 1
- Watchers: 4
- Forks: 7
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
To enable data-collector pass data-collector.yaml
YAML format:
```yaml
data_collector_base_directory: ""
collect_data_function: ""
collect_pod_logs: true|false # bool whether to collect logs if resource is a pod
```
YAML Example `ocp_utilities/data-collector.yaml`:
```yaml
data_collector_base_directory: "collected-info"
collect_data_function: "data_collector.collect_data"
collect_pod_logs: true
```
Either export path to yaml file in `OPENSHIFT_PYTHON_WRAPPER_DATA_COLLECTOR_YAML` or set `data_collector` in your py_config
The environment variable takes precedence over py_config.
To use dynamic base directory, export `OPENSHIFT_PYTHON_WRAPPER_DATA_COLLECTOR_DYNAMIC_BASE_DIR`
Example:
```
data_collector_base_directory = "/data/results/collected-info"
OPENSHIFT_PYTHON_WRAPPER_DATA_COLLECTOR_DYNAMIC_BASE_DIR = "dynamic_collector_test_dir"
Result: /data/results/dynamic_collector_test_dir/collected-info
```