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] Provide Policy for ETCD backup and monitor ETCD backup #169

Open
ch-stark opened this issue Nov 3, 2020 · 0 comments
Open

[FEATURE] Provide Policy for ETCD backup and monitor ETCD backup #169

ch-stark opened this issue Nov 3, 2020 · 0 comments
Labels
enhancement New feature or request

Comments

@ch-stark
Copy link

ch-stark commented Nov 3, 2020

Is your feature request related to a problem? Please describe.

We demonstrated RHACM to a Customer showing ETCD encryption and ETCD backup.
Customer would like to monitor both. This Enhancement is about how to monitor ETCD backup is working properly.

This policy currently does the backup:
https://github.com/ch-stark/policies-demo/blob/master/policies/backup-etcd-policy-v2.yaml

 Generated yaml-objects              

                kind: ServiceAccount
                kind: ClusterRoleBinding
                kind: PersistentVolumeClaim
                metadata:
                  name: etcd-backup
                kind: ConfigMap
                metadata:
                  name: etcd-backup-script
                kind: CronJob

it works so far

This is an example how to monitor that:
https://github.com/ch-stark/policies-demo/blob/master/policies/policy-checkjob.yaml

it checks if the job that does the backup has succeeded but this is not ideal

Describe the solution you'd like
Support for such a policy

Describe alternatives you've considered

We check manually:

oc logs cronjob-etcd-backup-1603974060-jj7bt
found latest kube-apiserver-pod: /etc/kubernetes/static-pod-resources/kube-apiserver-pod-9
found latest kube-controller-manager-pod: /etc/kubernetes/static-pod-resources/kube-controller-manager-pod-8
found latest kube-scheduler-pod: /etc/kubernetes/static-pod-resources/kube-scheduler-pod-8
found latest etcd-pod: /etc/kubernetes/static-pod-resources/etcd-pod-3
Snapshot saved at /assets/backup/snapshot_2020-10-29_122123.db
snapshot db and kube resources are successfully saved to /assets/backup
Copied backup files to PVC mount point.

We can monitor the timestamp of the backup

Additional context

We discussed that a CustomPolicyController might be needed
Thanks for any help!!!

@ch-stark ch-stark added the enhancement New feature or request label Nov 3, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant