forked from RedisLabs/redis-enterprise-k8s-docs
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Ubuntu
committed
Feb 8, 2021
1 parent
0c5c1c1
commit 920b0ac
Showing
28 changed files
with
414 additions
and
120 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
.idea | ||
*bundle.yaml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
## CRD's Schema<br/> | ||
|
||
|
||
Purpose: | ||
The schema is meant to ease the use of CRDs by restricting the fields to defined types and providing relevant description. | ||
|
||
|
||
### Work Flow - How add a new field: | ||
* Not all steps are always required | ||
|
||
#### 1. Update Tags: | ||
In the files | ||
+ `pkg/apis/app/v1alpha1/redisenterprisedatabase_types.go`<br/> | ||
+ `pkg/apis/app/v1alpha1/redisenterprisecluster_types.go`<br/> | ||
add tags on top of variables to mark allowed types (Enum)<br/> | ||
(see: https://book.kubebuilder.io/reference/markers/crd-validation.html).<br/> | ||
They will be used by the operator sdk when creating the scheme.<br/> | ||
**Default values** do not appear in the schema since the operator has its own default mechanism. | ||
|
||
|
||
#### 2 .Create the schema: | ||
1) Install operator-sdk version 0.17.2.<br/> | ||
See: https://sdk.operatorframework.io/docs/installation/install-operator-sdk/#install-from-github-release | ||
2) Run `operator-sdk generate crds` | ||
|
||
#### 3. Update the schema: | ||
- Edit the current schema in all of the relevant CRD yamls with the new section that was generated<br/> | ||
- Note that fields which are k8s objects might be very long - e.g. `SideContainersSpec` | ||
in this case -<br/>it appears in the schema but with no description in the fields since it extends the schema and is not unique for Redis Enterprise. | ||
|
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
crds/app_v1_redisenterprisecluster_cr.yaml → examples/v1/rec.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
apiVersion: app.redislabs.com/v1 | ||
kind: RedisEnterpriseCluster | ||
metadata: | ||
name: "redis-enterprise" | ||
name: rec | ||
spec: | ||
# Add fields here | ||
nodes: 3 |
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
apiVersion: app.redislabs.com/v1 | ||
kind: RedisEnterpriseCluster | ||
metadata: | ||
name: rec | ||
spec: | ||
# Add fields here | ||
nodes: 3 | ||
redisEnterpriseImageSpec: | ||
repository: registry.connect.redhat.com/redislabs/redis-enterprise | ||
versionTag: 6.0.12-57.rhel7-openshift | ||
redisEnterpriseServicesRiggerImageSpec: | ||
repository: registry.connect.redhat.com/redislabs/services-manager | ||
bootstrapperImageSpec: | ||
repository: registry.connect.redhat.com/redislabs/redis-enterprise-operator |
Oops, something went wrong.