Skip to content

Commit

Permalink
Add redisSentinel options for manifest backup/restore (#139)
Browse files Browse the repository at this point in the history
Signed-off-by: Anisur Rahman <[email protected]>
  • Loading branch information
anisurrahman75 authored Oct 16, 2024
1 parent 50d8c6b commit 35b1ce3
Show file tree
Hide file tree
Showing 3 changed files with 115 additions and 0 deletions.
32 changes: 32 additions & 0 deletions apis/core/v1alpha1/restoresession_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,38 @@ type ManifestRestoreOptions struct {
// Redis specifies the options for selecting particular Redis components to restore in manifest restore
// +optional
Redis *KubeDBManifestOptions `json:"redis,omitempty"`

// RedisSentinel specifies the options for selecting particular RedisSentinel components to restore in manifest restore
// +optional
RedisSentinel *RedisSentinelManifestOptions `json:"redisSentinel,omitempty"`
}

type RedisSentinelManifestOptions struct {
// RestoreNamespace specifies the Namespace where the restored files will be applied
// +optional
RestoreNamespace string `json:"restoreNamespace,omitempty"`

// Sentinel specifies whether to restore the Sentinel manifest or not
// +kubebuilder:default=true
// +optional
Sentinel *bool `json:"sentinel,omitempty"`

// SentinelName specifies the new name of the Sentinel yaml after restore
// +optional
SentinelName string `json:"SentinelName,omitempty"`

// AuthSecret specifies whether to restore the AuthSecret manifest or not
// +kubebuilder:default=true
// +optional
AuthSecret *bool `json:"authSecret,omitempty"`

// AuthSecretName specifies new name of the AuthSecret yaml after restore
// +optional
AuthSecretName string `json:"authSecretName,omitempty"`

// TLSIssuerRef specifies the name of the IssuerRef used for TLS configurations for both client and server
// +optional
TLSIssuerRef *core.TypedLocalObjectReference `json:"tlsIssuerRef,omitempty"`
}

type WorkloadManifestOptions struct {
Expand Down
35 changes: 35 additions & 0 deletions apis/core/v1alpha1/zz_generated.deepcopy.go

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

48 changes: 48 additions & 0 deletions crds/core.kubestash.com_restoresessions.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24464,6 +24464,54 @@ spec:
type: object
x-kubernetes-map-type: atomic
type: object
redisSentinel:
description: RedisSentinel specifies the options for selecting
particular RedisSentinel components to restore in manifest restore
properties:
SentinelName:
description: SentinelName specifies the new name of the Sentinel
yaml after restore
type: string
authSecret:
default: true
description: AuthSecret specifies whether to restore the AuthSecret
manifest or not
type: boolean
authSecretName:
description: AuthSecretName specifies new name of the AuthSecret
yaml after restore
type: string
restoreNamespace:
description: RestoreNamespace specifies the Namespace where
the restored files will be applied
type: string
sentinel:
default: true
description: Sentinel specifies whether to restore the Sentinel
manifest or not
type: boolean
tlsIssuerRef:
description: TLSIssuerRef specifies the name of the IssuerRef
used for TLS configurations for both client and server
properties:
apiGroup:
description: APIGroup is the group for the resource being
referenced. If APIGroup is not specified, the specified
Kind must be in the core API group. For any other third-party
types, APIGroup is required.
type: string
kind:
description: Kind is the type of resource being referenced
type: string
name:
description: Name is the name of resource being referenced
type: string
required:
- kind
- name
type: object
x-kubernetes-map-type: atomic
type: object
singlestore:
description: Singlestore specifies the options for selecting particular
Singlestore components to restore in manifest restore
Expand Down

0 comments on commit 35b1ce3

Please sign in to comment.