Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions api/v1alpha1/common_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,11 @@ type StorageSpec struct {
// +kubebuilder:validation:MinLength=1
// +kubebuilder:validation:MaxLength=63
Class string `json:"class,omitempty"`

// AccessModes contains the desired access modes the volume should have.
// More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes
// +optional
AccessModes []corev1.PersistentVolumeAccessMode `json:"accessModes,omitempty"`
}

// ContainerConfig defines generic container configuration.
Expand Down
10 changes: 4 additions & 6 deletions api/v1alpha1/shard_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ import (
// +kubebuilder:rbac:groups=apps,resources=deployments;statefulsets,verbs=get;list;watch;create;update;patch;delete
// +kubebuilder:rbac:groups="",resources=services,verbs=get;list;watch;create;update;patch;delete
// +kubebuilder:rbac:groups="",resources=persistentvolumeclaims,verbs=get;list;watch;create;update;patch;delete
// +kubebuilder:rbac:groups="",resources=configmaps,verbs=get;list;watch;create;update;patch;delete

// ============================================================================
// Shard Component Specs (Reusable)
Expand Down Expand Up @@ -77,13 +78,10 @@ type PoolSpec struct {
// +optional
Storage StorageSpec `json:"storage,omitempty"`

// BackupStorageType defines how backup storage is provided.
// Valid values are "hostPath" (for single-node testing) and "pvc" (for production).
// Defaults to "hostPath".
// BackupStorage defines the storage configuration for backup volumes.
// Shared across all pods in a pool. Defaults to same as Storage if not specified.
// +optional
// +kubebuilder:validation:Enum=hostPath;pvc
// +kubebuilder:default="hostPath"
BackupStorageType string `json:"backupStorageType,omitempty"`
BackupStorage StorageSpec `json:"backupStorage,omitempty"`

// Postgres container configuration.
// +optional
Expand Down
10 changes: 8 additions & 2 deletions api/v1alpha1/zz_generated.deepcopy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.