Skip to content
Open
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
271 changes: 254 additions & 17 deletions deploy/1-create-operator.yaml

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion deploy/crds/contrail.juniper.net_cassandras_crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ spec:
listKind: CassandraList
plural: cassandras
singular: cassandra
scope: Namespaced
scope: ""
subresources:
status: {}
validation:
Expand Down
2 changes: 1 addition & 1 deletion deploy/crds/contrail.juniper.net_commands_crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ spec:
listKind: CommandList
plural: commands
singular: command
scope: Namespaced
scope: ""
subresources:
status: {}
validation:
Expand Down
2 changes: 1 addition & 1 deletion deploy/crds/contrail.juniper.net_configs_crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ spec:
listKind: ConfigList
plural: configs
singular: config
scope: Namespaced
scope: ""
subresources:
status: {}
validation:
Expand Down
85 changes: 85 additions & 0 deletions deploy/crds/contrail.juniper.net_contrailmonitors_crd.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,85 @@
apiVersion: apiextensions.k8s.io/v1beta1
kind: CustomResourceDefinition
metadata:
name: contrailmonitors.contrail.juniper.net
spec:
group: contrail.juniper.net
names:
kind: Contrailmonitor
listKind: ContrailmonitorList
plural: contrailmonitors
singular: contrailmonitor
scope: Namespaced
subresources:
status: {}
validation:
openAPIV3Schema:
description: Contrailmonitor is the Schema for the contrailmonitors API
properties:
apiVersion:
description: 'APIVersion defines the versioned schema of this representation
of an object. Servers should convert recognized schemas to the latest
internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
type: string
kind:
description: 'Kind is a string value representing the REST resource this
object represents. Servers may infer this from the endpoint the client
submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
type: string
metadata:
type: object
spec:
description: ContrailmonitorSpec defines the desired state of Contrailmonitor
properties:
serviceConfiguration:
description: 'INSERT ADDITIONAL SPEC FIELDS - desired state of cluster
Important: Run "operator-sdk generate k8s" to regenerate code after
modifying this file Add custom validation using kubebuilder tags:
https://book-v1.book.kubebuilder.io/beyond_basics/generating_crd.html'
properties:
cassandraInstance:
type: string
commandInstance:
type: string
configInstance:
type: string
controlInstance:
type: string
keystoneInstance:
type: string
memcachedInstance:
type: string
postgresInstance:
type: string
provisionmanagerInstance:
type: string
rabbitmqInstance:
type: string
webuiInstance:
type: string
zookeeperInstance:
type: string
type: object
required:
- serviceConfiguration
type: object
status:
description: ContrailmonitorStatus defines the observed state of Contrailmonitor
properties:
active:
description: 'INSERT ADDITIONAL STATUS FIELD - define observed state
of cluster Important: Run "operator-sdk generate k8s" to regenerate
code after modifying this file Add custom validation using kubebuilder
tags: https://book-v1.book.kubebuilder.io/beyond_basics/generating_crd.html'
type: boolean
name:
type: string
required:
- name
type: object
type: object
version: v1alpha1
versions:
- name: v1alpha1
served: true
storage: true
43 changes: 43 additions & 0 deletions deploy/crds/contrail.juniper.net_contrailstatusmonitors_crd.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
apiVersion: apiextensions.k8s.io/v1beta1
kind: CustomResourceDefinition
metadata:
name: contrailstatusmonitors.contrail.juniper.net
spec:
additionalPrinterColumns:
- JSONPath: .status
description: Number of instances in group
name: Status
type: string
group: contrail.juniper.net
names:
kind: Contrailstatusmonitor
listKind: ContrailstatusmonitorList
plural: contrailstatusmonitors
singular: contrailstatusmonitor
scope: Namespaced
subresources: {}
validation:
openAPIV3Schema:
description: Contrailstatusmonitor is the Schema for the contrailstatusmonitors
API
properties:
apiVersion:
description: 'APIVersion defines the versioned schema of this representation
of an object. Servers should convert recognized schemas to the latest
internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
type: string
kind:
description: 'Kind is a string value representing the REST resource this
object represents. Servers may infer this from the endpoint the client
submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
type: string
metadata:
type: object
status:
type: string
type: object
version: v1alpha1
versions:
- name: v1alpha1
served: true
storage: true
2 changes: 1 addition & 1 deletion deploy/crds/contrail.juniper.net_controls_crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ spec:
listKind: ControlList
plural: controls
singular: control
scope: Namespaced
scope: ""
subresources:
status: {}
validation:
Expand Down
2 changes: 1 addition & 1 deletion deploy/crds/contrail.juniper.net_keystones_crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ spec:
listKind: KeystoneList
plural: keystones
singular: keystone
scope: Namespaced
scope: ""
subresources:
status: {}
validation:
Expand Down
2 changes: 1 addition & 1 deletion deploy/crds/contrail.juniper.net_kubemanagers_crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ spec:
listKind: KubemanagerList
plural: kubemanagers
singular: kubemanager
scope: Namespaced
scope: ""
subresources:
status: {}
validation:
Expand Down
83 changes: 82 additions & 1 deletion deploy/crds/contrail.juniper.net_managers_crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ spec:
listKind: ManagerList
plural: managers
singular: manager
scope: Namespaced
scope: ""
subresources:
status: {}
validation:
Expand Down Expand Up @@ -681,6 +681,76 @@ spec:
type: object
type: object
type: object
contrailmonitor:
description: Contrailmonitor is the Schema for the contrailmonitors
API
properties:
apiVersion:
description: 'APIVersion defines the versioned schema of this
representation of an object. Servers should convert recognized
schemas to the latest internal value, and may reject unrecognized
values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
type: string
kind:
description: 'Kind is a string value representing the REST resource
this object represents. Servers may infer this from the endpoint
the client submits requests to. Cannot be updated. In CamelCase.
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
type: string
metadata:
type: object
spec:
description: ContrailmonitorSpec defines the desired state of
Contrailmonitor
properties:
serviceConfiguration:
description: 'INSERT ADDITIONAL SPEC FIELDS - desired state
of cluster Important: Run "operator-sdk generate k8s"
to regenerate code after modifying this file Add custom
validation using kubebuilder tags: https://book-v1.book.kubebuilder.io/beyond_basics/generating_crd.html'
properties:
cassandraInstance:
type: string
commandInstance:
type: string
configInstance:
type: string
controlInstance:
type: string
keystoneInstance:
type: string
memcachedInstance:
type: string
postgresInstance:
type: string
provisionmanagerInstance:
type: string
rabbitmqInstance:
type: string
webuiInstance:
type: string
zookeeperInstance:
type: string
type: object
required:
- serviceConfiguration
type: object
status:
description: ContrailmonitorStatus defines the observed state
of Contrailmonitor
properties:
active:
description: 'INSERT ADDITIONAL STATUS FIELD - define observed
state of cluster Important: Run "operator-sdk generate
k8s" to regenerate code after modifying this file Add
custom validation using kubebuilder tags: https://book-v1.book.kubebuilder.io/beyond_basics/generating_crd.html'
type: boolean
name:
type: string
required:
- name
type: object
type: object
controls:
items:
description: Control is the Schema for the controls API.
Expand Down Expand Up @@ -2604,6 +2674,17 @@ spec:
name:
type: string
type: object
contrailmonitor:
description: ServiceStatus provides information on the current status
of the service.
properties:
active:
type: boolean
created:
type: boolean
name:
type: string
type: object
controls:
items:
description: ServiceStatus provides information on the current status
Expand Down
2 changes: 1 addition & 1 deletion deploy/crds/contrail.juniper.net_postgres_crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ spec:
listKind: PostgresList
plural: postgres
singular: postgres
scope: Namespaced

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please update operator-sdk to version v0.17.1 as described in documentation.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As per document, for 2008R we are using the older version, I have noticed u have changes done in master not in 2008R.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

but this is PR to master

scope: ""
subresources:
status: {}
validation:
Expand Down
2 changes: 1 addition & 1 deletion deploy/crds/contrail.juniper.net_rabbitmqs_crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ spec:
listKind: RabbitmqList
plural: rabbitmqs
singular: rabbitmq
scope: Namespaced
scope: ""
subresources:
status: {}
validation:
Expand Down
2 changes: 1 addition & 1 deletion deploy/crds/contrail.juniper.net_swiftproxies_crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ spec:
listKind: SwiftProxyList
plural: swiftproxies
singular: swiftproxy
scope: Namespaced
scope: ""
subresources:
status: {}
validation:
Expand Down
2 changes: 1 addition & 1 deletion deploy/crds/contrail.juniper.net_swifts_crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ spec:
listKind: SwiftList
plural: swifts
singular: swift
scope: Namespaced
scope: ""
subresources:
status: {}
validation:
Expand Down
2 changes: 1 addition & 1 deletion deploy/crds/contrail.juniper.net_swiftstorages_crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ spec:
listKind: SwiftStorageList
plural: swiftstorages
singular: swiftstorage
scope: Namespaced
scope: ""
subresources:
status: {}
validation:
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
apiVersion: contrail.juniper.net/v1alpha1
kind: Contrailmonitor
metadata:
name: example-contrailmonitor
spec:
# Add fields here
size: 3
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
apiVersion: contrail.juniper.net/v1alpha1
kind: Contrailstatusmonitor
metadata:
name: cassandra1
status: functional
---
apiVersion: contrail.juniper.net/v1alpha1
kind: Contrailstatusmonitor
metadata:
name: zookeeper1
status: non-functional
2 changes: 1 addition & 1 deletion deploy/crds/contrail.juniper.net_vrouters_crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ spec:
listKind: VrouterList
plural: vrouters
singular: vrouter
scope: Namespaced
scope: ""
subresources:
status: {}
validation:
Expand Down
2 changes: 1 addition & 1 deletion deploy/crds/contrail.juniper.net_webuis_crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ spec:
listKind: WebuiList
plural: webuis
singular: webui
scope: Namespaced
scope: ""
subresources:
status: {}
validation:
Expand Down
2 changes: 1 addition & 1 deletion deploy/crds/contrail.juniper.net_zookeepers_crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ spec:
listKind: ZookeeperList
plural: zookeepers
singular: zookeeper
scope: Namespaced
scope: ""
subresources:
status: {}
validation:
Expand Down
2 changes: 2 additions & 0 deletions deploy/role.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,8 @@ rules:
- swifts
- memcacheds
- fernetkeymanagers
- contrailmonitors
- contrailstatusmonitors
verbs:
- '*'
- apiGroups:
Expand Down
2 changes: 2 additions & 0 deletions pkg/apis/contrail/v1alpha1/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ go_library(
"cassandra_types.go",
"command_types.go",
"config_types.go",
"contrailmonitor_types.go",
"contrailstatusmonitor_types.go",
"control_types.go",
"defaults.go",
"doc.go",
Expand Down
Loading