diff --git a/PROJECT b/PROJECT index 6a55f0773..5b3f4a2d9 100644 --- a/PROJECT +++ b/PROJECT @@ -1,3 +1,7 @@ +# Code generated by tool. DO NOT EDIT. +# This file is used to track the info used to scaffold your project +# and allow the plugins properly work. +# More info: https://book.kubebuilder.io/reference/project-config.html domain: aerospike.com layout: - go.kubebuilder.io/v4 diff --git a/api/v1/zz_generated.deepcopy.go b/api/v1/zz_generated.deepcopy.go index 8a1a8f646..1b6fdca62 100644 --- a/api/v1/zz_generated.deepcopy.go +++ b/api/v1/zz_generated.deepcopy.go @@ -1,5 +1,4 @@ //go:build !ignore_autogenerated -// +build !ignore_autogenerated /* Copyright 2021. diff --git a/api/v1beta1/aerospikebackup_types.go b/api/v1beta1/aerospikebackup_types.go index a54928a93..87f06ff4f 100644 --- a/api/v1beta1/aerospikebackup_types.go +++ b/api/v1beta1/aerospikebackup_types.go @@ -83,6 +83,7 @@ type AerospikeBackupStatus struct { // +kubebuilder:object:root=true // +kubebuilder:subresource:status +// +kubebuilder:metadata:annotations="aerospike-kubernetes-operator/version=3.3.1" // +kubebuilder:printcolumn:name="Backup Service Name",type=string,JSONPath=`.spec.backupService.name` // +kubebuilder:printcolumn:name="Backup Service Namespace",type=string,JSONPath=`.spec.backupService.namespace` // +kubebuilder:printcolumn:name="Age",type="date",JSONPath=".metadata.creationTimestamp" diff --git a/api/v1beta1/aerospikebackupservice_types.go b/api/v1beta1/aerospikebackupservice_types.go index bec63bee8..123af3401 100644 --- a/api/v1beta1/aerospikebackupservice_types.go +++ b/api/v1beta1/aerospikebackupservice_types.go @@ -41,6 +41,7 @@ const ( ) // AerospikeBackupServiceSpec defines the desired state of AerospikeBackupService +// +k8s:openapi-gen=true // //nolint:govet // for readability type AerospikeBackupServiceSpec struct { @@ -104,6 +105,7 @@ type AerospikeBackupServiceStatus struct { // +kubebuilder:object:root=true // +kubebuilder:subresource:status +// +kubebuilder:metadata:annotations="aerospike-kubernetes-operator/version=3.3.1" // +kubebuilder:printcolumn:name="Image",type=string,JSONPath=`.spec.image` // +kubebuilder:printcolumn:name="Service Type",type=string,JSONPath=`.spec.service.type` // +kubebuilder:printcolumn:name="Phase",type=string,JSONPath=`.status.phase` diff --git a/api/v1beta1/aerospikerestore_types.go b/api/v1beta1/aerospikerestore_types.go index fe64b8402..d7562df6e 100644 --- a/api/v1beta1/aerospikerestore_types.go +++ b/api/v1beta1/aerospikerestore_types.go @@ -84,6 +84,7 @@ type AerospikeRestoreStatus struct { // +kubebuilder:object:root=true // +kubebuilder:subresource:status +// +kubebuilder:metadata:annotations="aerospike-kubernetes-operator/version=3.3.1" // +kubebuilder:printcolumn:name="Backup Service Name",type=string,JSONPath=`.spec.backupService.name` // +kubebuilder:printcolumn:name="Backup Service Namespace",type=string,JSONPath=`.spec.backupService.namespace` // +kubebuilder:printcolumn:name="Phase",type=string,JSONPath=`.status.phase` diff --git a/api/v1beta1/zz_generated.deepcopy.go b/api/v1beta1/zz_generated.deepcopy.go index 1930b2fcf..040a31a03 100644 --- a/api/v1beta1/zz_generated.deepcopy.go +++ b/api/v1beta1/zz_generated.deepcopy.go @@ -1,5 +1,4 @@ //go:build !ignore_autogenerated -// +build !ignore_autogenerated /* Copyright 2021. diff --git a/config/crd/bases/asdb.aerospike.com_aerospikebackups.yaml b/config/crd/bases/asdb.aerospike.com_aerospikebackups.yaml index d9c75563c..6d7d8a4d3 100644 --- a/config/crd/bases/asdb.aerospike.com_aerospikebackups.yaml +++ b/config/crd/bases/asdb.aerospike.com_aerospikebackups.yaml @@ -3,6 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: + aerospike-kubernetes-operator/version: 3.3.1 controller-gen.kubebuilder.io/version: v0.14.0 name: aerospikebackups.asdb.aerospike.com spec: diff --git a/config/crd/bases/asdb.aerospike.com_aerospikebackupservices.yaml b/config/crd/bases/asdb.aerospike.com_aerospikebackupservices.yaml index c2812b04a..0c8159c67 100644 --- a/config/crd/bases/asdb.aerospike.com_aerospikebackupservices.yaml +++ b/config/crd/bases/asdb.aerospike.com_aerospikebackupservices.yaml @@ -3,6 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: + aerospike-kubernetes-operator/version: 3.3.1 controller-gen.kubebuilder.io/version: v0.14.0 name: aerospikebackupservices.asdb.aerospike.com spec: diff --git a/config/crd/bases/asdb.aerospike.com_aerospikerestores.yaml b/config/crd/bases/asdb.aerospike.com_aerospikerestores.yaml index 220fd6c77..b29b2678d 100644 --- a/config/crd/bases/asdb.aerospike.com_aerospikerestores.yaml +++ b/config/crd/bases/asdb.aerospike.com_aerospikerestores.yaml @@ -3,6 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: + aerospike-kubernetes-operator/version: 3.3.1 controller-gen.kubebuilder.io/version: v0.14.0 name: aerospikerestores.asdb.aerospike.com spec: diff --git a/config/default/kustomization.yaml b/config/default/kustomization.yaml index 1b83bb8ba..8024ec686 100644 --- a/config/default/kustomization.yaml +++ b/config/default/kustomization.yaml @@ -49,66 +49,67 @@ patches: - path: webhookcainjection_patch.yaml # the following config is for teaching kustomize how to do var substitution - # [CERTMANAGER] To enable cert-manager, uncomment all sections with 'CERTMANAGER' prefix. +# [CERTMANAGER] To enable cert-manager, uncomment all sections with 'CERTMANAGER' prefix. +# Uncomment below to enable the CA injection annotations in the admission webhooks and CRDs replacements: -- source: - fieldPath: metadata.namespace - kind: Certificate - name: serving-cert - targets: - - select: - kind: ValidatingWebhookConfiguration - fieldPaths: - - .metadata.annotations.[cert-manager.io/inject-ca-from] - options: - delimiter: '/' - index: 0 - create: true - - select: - kind: MutatingWebhookConfiguration - fieldPaths: - - .metadata.annotations.[cert-manager.io/inject-ca-from] - options: - delimiter: '/' - index: 0 - create: true - - select: - kind: CustomResourceDefinition - fieldPaths: - - .metadata.annotations.[cert-manager.io/inject-ca-from] - options: - delimiter: '/' - index: 0 - create: true -- source: - fieldPath: metadata.name - kind: Certificate - name: serving-cert - targets: - - select: - kind: ValidatingWebhookConfiguration - fieldPaths: - - .metadata.annotations.[cert-manager.io/inject-ca-from] - options: - delimiter: '/' - index: 1 - create: true - - select: - kind: MutatingWebhookConfiguration - fieldPaths: - - .metadata.annotations.[cert-manager.io/inject-ca-from] - options: - delimiter: '/' - index: 1 - create: true - - select: - kind: CustomResourceDefinition - fieldPaths: - - .metadata.annotations.[cert-manager.io/inject-ca-from] - options: - delimiter: '/' - index: 1 - create: true +#- source: +# fieldPath: metadata.namespace +# kind: Certificate +# name: serving-cert +# targets: +# - select: +# kind: ValidatingWebhookConfiguration +# fieldPaths: +# - .metadata.annotations.[cert-manager.io/inject-ca-from] +# options: +# delimiter: '/' +# index: 0 +# create: true +# - select: +# kind: MutatingWebhookConfiguration +# fieldPaths: +# - .metadata.annotations.[cert-manager.io/inject-ca-from] +# options: +# delimiter: '/' +# index: 0 +# create: true +# - select: +# kind: CustomResourceDefinition +# fieldPaths: +# - .metadata.annotations.[cert-manager.io/inject-ca-from] +# options: +# delimiter: '/' +# index: 0 +# create: true +#- source: +# fieldPath: metadata.name +# kind: Certificate +# name: serving-cert +# targets: +# - select: +# kind: ValidatingWebhookConfiguration +# fieldPaths: +# - .metadata.annotations.[cert-manager.io/inject-ca-from] +# options: +# delimiter: '/' +# index: 1 +# create: true +# - select: +# kind: MutatingWebhookConfiguration +# fieldPaths: +# - .metadata.annotations.[cert-manager.io/inject-ca-from] +# options: +# delimiter: '/' +# index: 1 +# create: true +# - select: +# kind: CustomResourceDefinition +# fieldPaths: +# - .metadata.annotations.[cert-manager.io/inject-ca-from] +# options: +# delimiter: '/' +# index: 1 +# create: true - source: fieldPath: metadata.namespace kind: Service diff --git a/config/manager/manager.yaml b/config/manager/manager.yaml index 9577e5084..b2f978077 100644 --- a/config/manager/manager.yaml +++ b/config/manager/manager.yaml @@ -35,8 +35,8 @@ spec: imagePullPolicy: IfNotPresent resources: limits: - cpu: 200m - memory: 256Mi + cpu: 400m + memory: 512Mi requests: cpu: 10m memory: 64Mi diff --git a/config/samples/aerospikebackupservice.yaml b/config/samples/aerospikebackupservice.yaml index 101412328..c0c07c74a 100644 --- a/config/samples/aerospikebackupservice.yaml +++ b/config/samples/aerospikebackupservice.yaml @@ -4,7 +4,7 @@ metadata: name: aerospikebackupservice-sample namespace: aerospike spec: - image: aerospike/aerospike-backup-service:1.0.0 + image: aerospike/aerospike-backup-service:2.0.0 config: service: http: diff --git a/helm-charts/aerospike-backup-service/README.md b/helm-charts/aerospike-backup-service/README.md index 81a16e16e..95a58423e 100644 --- a/helm-charts/aerospike-backup-service/README.md +++ b/helm-charts/aerospike-backup-service/README.md @@ -38,17 +38,17 @@ helm install aerospike-backup-service aerospike/aerospike-backup-service \ ## Configurations -| Name | Description | Default | -|------------------------------|-------------------------------------------------------------------------------|------------------------------------------------------------------------------| -| `image.repository` | Aerospike backup service container image repository | `aerospike.jfrog.io/ecosystem-container-prod-local/aerospike-backup-service` | -| `image.tag` | Aerospike backup service container image tag | `1.0.0` | -| `customLabels` | Custom labels to add on the AerospikeBackupService resource | `{}` (nil) | -| `serviceAccount.create` | Enable ServiceAccount creation for Aerospike backup service. | true | -| `serviceAccount.annotations` | ServiceAccount annotations | `{}` (nil) | -| `backupServiceConfig` | Aerospike backup service configuration | `{}` (nil) | -| `secrets` | Secrets to be mounted in the Aerospike Backup Service pod like aws creds etc. | `[]` (nil) | -| `resources` | Aerospike backup service pod resource requirements | `{}` (nil) | -| `service` | Kubernetes service configuration for Aerospike backup service | `{}` (nil) | +| Name | Description | Default | +|------------------------------|-------------------------------------------------------------------------------|--------------------------------------| +| `image.repository` | Aerospike backup service container image repository | `aerospike/aerospike-backup-service` | +| `image.tag` | Aerospike backup service container image tag | `2.0.0` | +| `customLabels` | Custom labels to add on the AerospikeBackupService resource | `{}` (nil) | +| `serviceAccount.create` | Enable ServiceAccount creation for Aerospike backup service. | true | +| `serviceAccount.annotations` | ServiceAccount annotations | `{}` (nil) | +| `backupServiceConfig` | Aerospike backup service configuration | `{}` (nil) | +| `secrets` | Secrets to be mounted in the Aerospike Backup Service pod like aws creds etc. | `[]` (nil) | +| `resources` | Aerospike backup service pod resource requirements | `{}` (nil) | +| `service` | Kubernetes service configuration for Aerospike backup service | `{}` (nil) | ### Configurations Explained diff --git a/helm-charts/aerospike-backup-service/values.yaml b/helm-charts/aerospike-backup-service/values.yaml index 5b7b7cf0f..4a1d0a15a 100644 --- a/helm-charts/aerospike-backup-service/values.yaml +++ b/helm-charts/aerospike-backup-service/values.yaml @@ -10,8 +10,8 @@ nameOverride: "" ## Image is the image for the backup service. image: - repository: aerospike.jfrog.io/ecosystem-container-prod-local/aerospike-backup-service - tag: "1.0.0" + repository: aerospike/aerospike-backup-service + tag: "2.0.0" ## Custom labels that will be applied on the AerospikeBackupService resource customLabels: {} diff --git a/helm-charts/aerospike-kubernetes-operator/crds/customresourcedefinition_aerospikebackups.asdb.aerospike.com.yaml b/helm-charts/aerospike-kubernetes-operator/crds/customresourcedefinition_aerospikebackups.asdb.aerospike.com.yaml index d9c75563c..6d7d8a4d3 100644 --- a/helm-charts/aerospike-kubernetes-operator/crds/customresourcedefinition_aerospikebackups.asdb.aerospike.com.yaml +++ b/helm-charts/aerospike-kubernetes-operator/crds/customresourcedefinition_aerospikebackups.asdb.aerospike.com.yaml @@ -3,6 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: + aerospike-kubernetes-operator/version: 3.3.1 controller-gen.kubebuilder.io/version: v0.14.0 name: aerospikebackups.asdb.aerospike.com spec: diff --git a/helm-charts/aerospike-kubernetes-operator/crds/customresourcedefinition_aerospikebackupservices.asdb.aerospike.com.yaml b/helm-charts/aerospike-kubernetes-operator/crds/customresourcedefinition_aerospikebackupservices.asdb.aerospike.com.yaml index c2812b04a..0c8159c67 100644 --- a/helm-charts/aerospike-kubernetes-operator/crds/customresourcedefinition_aerospikebackupservices.asdb.aerospike.com.yaml +++ b/helm-charts/aerospike-kubernetes-operator/crds/customresourcedefinition_aerospikebackupservices.asdb.aerospike.com.yaml @@ -3,6 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: + aerospike-kubernetes-operator/version: 3.3.1 controller-gen.kubebuilder.io/version: v0.14.0 name: aerospikebackupservices.asdb.aerospike.com spec: diff --git a/helm-charts/aerospike-kubernetes-operator/crds/customresourcedefinition_aerospikerestores.asdb.aerospike.com.yaml b/helm-charts/aerospike-kubernetes-operator/crds/customresourcedefinition_aerospikerestores.asdb.aerospike.com.yaml index 220fd6c77..b29b2678d 100644 --- a/helm-charts/aerospike-kubernetes-operator/crds/customresourcedefinition_aerospikerestores.asdb.aerospike.com.yaml +++ b/helm-charts/aerospike-kubernetes-operator/crds/customresourcedefinition_aerospikerestores.asdb.aerospike.com.yaml @@ -3,6 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: + aerospike-kubernetes-operator/version: 3.3.1 controller-gen.kubebuilder.io/version: v0.14.0 name: aerospikerestores.asdb.aerospike.com spec: diff --git a/helm-charts/aerospike-kubernetes-operator/values.yaml b/helm-charts/aerospike-kubernetes-operator/values.yaml index abcc33c9d..6f52743cd 100644 --- a/helm-charts/aerospike-kubernetes-operator/values.yaml +++ b/helm-charts/aerospike-kubernetes-operator/values.yaml @@ -36,8 +36,8 @@ aerospikeKubernetesInitRegistry: "docker.io" ## Resources - limits / requests resources: limits: - cpu: 200m - memory: 256Mi + cpu: 400m + memory: 512Mi requests: cpu: 10m memory: 64Mi diff --git a/test/backup_service/test_utils.go b/test/backup_service/test_utils.go index 1b27d563a..41ea4ef75 100644 --- a/test/backup_service/test_utils.go +++ b/test/backup_service/test_utils.go @@ -23,7 +23,7 @@ import ( "github.com/aerospike/aerospike-kubernetes-operator/test" ) -const BackupServiceImage = "aerospike/aerospike-backup-service:1.0.0" +const BackupServiceImage = "aerospike/aerospike-backup-service:2.0.0" const ( timeout = 2 * time.Minute