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

Add EtcdCluster resource examples #114

Merged
merged 1 commit into from
Apr 3, 2024
Merged

Add EtcdCluster resource examples #114

merged 1 commit into from
Apr 3, 2024

Conversation

kvaps
Copy link
Member

@kvaps kvaps commented Apr 2, 2024

following up #109 (comment)

Here are examples for:

  • Simple cluster with few replicas
  • Cluster with custom image
  • Cluster with persistent storage
  • Cluster with resources
  • Cluster with all field specified

@kvaps
Copy link
Member Author

kvaps commented Apr 2, 2024

I’ll personally raise the question again whether we should replace:

spec.pod --> spec.podTemplate
spec.service --> spec.serviceTemplate
spec.podDisruptionBudget --> spec.podDisruptionBudgetTemplate

piraeus-operator and elk-operator use it this way

Copy link
Member

@sircthulhu sircthulhu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

I would personally add etcdcluster-with-default-pdb.yaml

---
apiVersion: etcd.aenix.io/v1alpha1
kind: EtcdCluster
metadata:
  name: test
  namespace: default
spec:
  replicas: 3
  podDisruptionBudget: {}

@kvaps kvaps force-pushed the examples branch 2 times, most recently from d497a92 to 383d5b6 Compare April 3, 2024 08:33
@kvaps
Copy link
Member Author

kvaps commented Apr 3, 2024

PR rebased after internal discussion to use Template suffixes for configuring Kubernetes entities.

Another advantage of using the Template suffixes is that it serves as a contract to adhere to the Kubernetes specifications.

What we have in storage and options is validated and processed by our logic, and the specifications there are strictly our own. However, what is in *Template follows the Kubernetes specifications and is intuitively understandable.

@kvaps kvaps requested a review from sircthulhu April 3, 2024 10:13
@kvaps kvaps requested a review from lllamnyp April 3, 2024 14:50
@kvaps kvaps enabled auto-merge (squash) April 3, 2024 14:51
@kvaps kvaps merged commit 659291d into main Apr 3, 2024
5 checks passed
@kvaps kvaps deleted the examples branch April 3, 2024 15:14
@kvaps kvaps added this to the v0.1.0 milestone Apr 3, 2024
@sircthulhu sircthulhu added the documentation Improvements or additions to documentation label Apr 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

5 participants