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

Modify models #10

Merged
merged 4 commits into from
Mar 9, 2024
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
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,6 @@ Dockerfile.cross
*.swp
*.swo
*~

# Resource examples for preparing test environment on local machine
example.local
10 changes: 5 additions & 5 deletions PROJECT
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@
domain: gobackup.io
layout:
- go.kubebuilder.io/v4
projectName: backup-operator
projectName: gobackup-operator
repo: gobackup.io/gobackup/gobackup-operator
resources:
- api:
crdVersion: v1
namespaced: true
controller: true
domain: gobackup.io
group: backup
group: gobackup
kind: BackupModel
path: gobackup.io/gobackup/gobackup-operator/api/v1
version: v1
Expand All @@ -22,7 +22,7 @@ resources:
namespaced: true
controller: true
domain: gobackup.io
group: backup
group: gobackup
kind: CronBackup
path: gobackup.io/gobackup/gobackup-operator/api/v1
version: v1
Expand All @@ -31,7 +31,7 @@ resources:
namespaced: true
controller: true
domain: gobackup.io
group: backup
group: storage.gobackup
kind: S3
path: gobackup.io/gobackup/gobackup-operator/api/v1
version: v1
Expand All @@ -40,7 +40,7 @@ resources:
namespaced: true
controller: true
domain: gobackup.io
group: backup
group: database.gobackup
kind: PostgreSQL
path: gobackup.io/gobackup/gobackup-operator/api/v1
version: v1
Expand Down
5 changes: 2 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
# backup-operator
Handling backup from various storages.

# gobackup-operator

**Please note:** This project is currently under active development.

Handling backup from various storages.

## Description
A Kubernetes operator for backing up various storages, including Etcd, based on [gobackup](https://github.com/gobackup/gobackup).
Expand Down
17 changes: 12 additions & 5 deletions api/v1/backupmodel_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,16 +20,23 @@ import (
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
)

// EDIT THIS FILE! THIS IS SCAFFOLDING FOR YOU TO OWN!
// NOTE: json tags are required. Any new fields you add must have json tags for the fields to be serialized.

// BackupModelSpec defines the desired state of BackupModel
type BackupModelSpec struct {
Description string `json:"description"`
CompressWith Compress `json:"compress_with"`
EncodeWith Encode `json:"encode_with"`
BeforeScript string `json:"before_script"`
AfterScript string `json:"after_script"`
CompressWith Compress `json:"compressWith"`
EncodeWith Encode `json:"encodeWith"`
BeforeScript string `json:"beforeScript"`
AfterScript string `json:"afterScript"`
}

type BackupModelSpecConfig struct {
Description string `json:"description" yaml:"description,omitempty"`
CompressWith Compress `json:"compress_with" yaml:"compress_with,omitempty"`
EncodeWith Encode `json:"encode_with" yaml:"encode_with,omitempty"`
BeforeScript string `json:"before_script" yaml:"before_script,omitempty"`
AfterScript string `json:"after_script" yaml:"after_script,omitempty"`
}

// BackupModelStatus defines the observed state of BackupModel
Expand Down
17 changes: 17 additions & 0 deletions api/v1/zz_generated.deepcopy.go

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

89 changes: 0 additions & 89 deletions config/crd/bases/backup.github.com_backupmodels.yaml

This file was deleted.

80 changes: 0 additions & 80 deletions config/crd/bases/backup.github.com_cronbackups.yaml

This file was deleted.

67 changes: 0 additions & 67 deletions config/crd/bases/backup.github.com_postgresqls.yaml

This file was deleted.

Loading
Loading