Skip to content
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

[feature] add --force (or similar) to 'pmm-admin add' #3117

Open
1 task done
brevilo opened this issue Aug 1, 2024 · 2 comments
Open
1 task done

[feature] add --force (or similar) to 'pmm-admin add' #3117

brevilo opened this issue Aug 1, 2024 · 2 comments
Assignees
Labels
feature Feature request migrate to jira tasks that needs to be migrated to jira

Comments

@brevilo
Copy link

brevilo commented Aug 1, 2024

Description

More often than not tools like PMM get deployed non-interactively nowadays, using tools like Saltstack. These typically use state descriptions for the configurations they manage. It would be helpful if pmm-admin would be designed in such a way, that its commands can be used repeatedly (idempotent) to ensure a desired config state is effective. For instance, calling pmm-admin add isn't idempotent as it fails when the service to be added already exists.

Suggested solution

One way to implement this would be to add a --force option that doesn't fail if the service exists but, if anything, updates its config. That is, unless a real error occurs. That should of course still return a non-zero value and some useful message on stderr.

Additional context

Have a look at pmm-admin config which has a --force option to simply allow repeated calls and returns a 0, unless a real error occurs.

Ideally all config-changing commands would allow such use.

Code of Conduct

  • I agree to follow this project's Code of Conduct
@brevilo brevilo added the feature Feature request label Aug 1, 2024
@BupycHuk BupycHuk added the migrate to jira tasks that needs to be migrated to jira label Aug 7, 2024
@BupycHuk
Copy link
Member

BupycHuk commented Aug 7, 2024

Hi @brevilo, idea looks good to us. We will add it to our Jira to track it.

@brevilo
Copy link
Author

brevilo commented Aug 30, 2024

Thanks. This feature is crucial for us since it blocks rolling out PMM for a larger test. Please add a cross-reference as soon as you have it (couldn't find it yet), so I can track its progress 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature Feature request migrate to jira tasks that needs to be migrated to jira
Projects
None yet
Development

No branches or pull requests

2 participants