-
Notifications
You must be signed in to change notification settings - Fork 20
feat: POC: Added support for "rhc collector" #245
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Draft
jirihnidek
wants to merge
18
commits into
main
Choose a base branch
from
jhnidek/collector
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
* Card ID: CCT-1439 * Added all "rhc collector" sub-commands, but most of them are no-op ATM * Implemented "rhc collector list" * Implemented "rhc collector list --format json" Signed-off-by: Jiri Hnidek <[email protected]>
* Card ID: CCT-CCT-1439 * It does not display all required information, but it display majority of information * The output to JSON format is also limited Signed-off-by: Jiri Hnidek <[email protected]>
* Card ID: CCT-1439 * It is possible to run collector, archiver and uploader * The output to JSON format is not implemented yet Signed-off-by: Jiri Hnidek <[email protected]>
* Each collector sub-command was moved to its own module. Signed-off-by: Jiri Hnidek <[email protected]>
9383db5
to
24ded2e
Compare
* When version command is defined in the collector configuration file, then this version command is used for gathering version * When it is not possible to run run version command, then the error is written to log and "-" is used on the place of version value Signed-off-by: Jiri Hnidek <[email protected]>
* When "/bin/bash -c" is used for running commands, then it is possible to use all features of bash (e.g. set env. var. in the command, redirect stderr, etc.) Signed-off-by: Jiri Hnidek <[email protected]>
* The content_type should be specified as CLI option of uploader. No need to set it as configuration option of uploader Signed-off-by: Jiri Hnidek <[email protected]>
Signed-off-by: Jiri Hnidek <[email protected]>
* It is possible to enable and disable collector timer and start service using --now Signed-off-by: Jiri Hnidek <[email protected]>
* Information about timers was added * The last_run.json is also used * Some refactoring Signed-off-by: Jiri Hnidek <[email protected]>
* Moved some generic code to collector.go * The "run collector" just prints help Signed-off-by: Jiri Hnidek <[email protected]>
* The user can be defined in the collector config in the exec section [exec] user = <USERNAME> * When user is not defined, then collector is run using current user * The user used for running collector has to be member of grou `rhc-collector` * Small changes not related to this commit. ;-) Signed-off-by: Jiri Hnidek <[email protected]>
* The /var/cache/rhc/collector.d/<COLLECTOR_ID> has to be writable by system user and group used for running collector * Small refactoring Signed-off-by: Jiri Hnidek <[email protected]>
Signed-off-by: Jiri Hnidek <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
rhc collector
sub-commands, but most of them are no-op ATMrhc collector run
rhc collector run
as non-root userrhc collector info
rhc collector list
rhc collector timers
rhc collector enable
rhc collector disable