-
Notifications
You must be signed in to change notification settings - Fork 55
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
1 parent
ecb0085
commit 17da46b
Showing
9 changed files
with
205 additions
and
107 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
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,7 @@ | ||
apiVersion: redhat-cop.redhat.io/v1alpha1 | ||
kind: NamespaceConfig | ||
metadata: | ||
name: example-namespaceconfig | ||
spec: | ||
# Add fields here | ||
size: 3 |
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,47 @@ | ||
apiVersion: apiextensions.k8s.io/v1beta1 | ||
kind: CustomResourceDefinition | ||
metadata: | ||
name: namespaceconfigs.redhatcop.redhat.io | ||
spec: | ||
group: redhatcop.redhat.io | ||
names: | ||
kind: NamespaceConfig | ||
listKind: NamespaceConfigList | ||
plural: namespaceconfigs | ||
singular: namespaceconfig | ||
scope: Namespaced | ||
validation: | ||
openAPIV3Schema: | ||
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/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/api-conventions.md#types-kinds' | ||
type: string | ||
metadata: | ||
type: object | ||
spec: | ||
properties: | ||
resources: | ||
items: | ||
type: object | ||
type: array | ||
selector: | ||
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.kubebuilder.io/beyond_basics/generating_crd.html' | ||
type: object | ||
type: object | ||
status: | ||
type: object | ||
version: v1alpha1 | ||
versions: | ||
- name: v1alpha1 | ||
served: true | ||
storage: true |
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,54 +1,46 @@ | ||
apiVersion: rbac.authorization.k8s.io/v1 | ||
kind: Role | ||
apiVersion: rbac.authorization.k8s.io/v1 | ||
metadata: | ||
creationTimestamp: null | ||
name: namespace-configuration-operator | ||
rules: | ||
# leader election | ||
- apiGroups: | ||
- "" | ||
resources: | ||
- configmaps | ||
- pods | ||
verbs: | ||
- "*" | ||
#Metrics | ||
- apiGroups: | ||
- "" | ||
resources: | ||
- services | ||
- endpoints | ||
- persistentvolumeclaims | ||
- events | ||
- configmaps | ||
- secrets | ||
verbs: | ||
- '*' | ||
- "*" | ||
#Metrics | ||
- apiGroups: | ||
- apps | ||
- "apps" | ||
resources: | ||
- deployments | ||
- daemonsets | ||
- replicasets | ||
- statefulsets | ||
verbs: | ||
- '*' | ||
- deployments | ||
verbs: | ||
- "get" | ||
- "list" | ||
# Metrics | ||
- apiGroups: | ||
- monitoring.coreos.com | ||
resources: | ||
- servicemonitors | ||
verbs: | ||
- get | ||
- create | ||
- "get" | ||
- "create" | ||
# Metrics | ||
- apiGroups: | ||
- apps | ||
resourceNames: | ||
- namespace-configuration-operator | ||
resources: | ||
- deployments/finalizers | ||
resourceNames: | ||
- cert-utils-operator | ||
verbs: | ||
- update | ||
- apiGroups: | ||
- redhat-cop.io | ||
resources: | ||
- '*' | ||
verbs: | ||
- '*' | ||
- apiGroups: | ||
- redhat-cop.redhat.io | ||
resources: | ||
- '*' | ||
verbs: | ||
- '*' | ||
- "update" |
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,11 +1,23 @@ | ||
kind: RoleBinding | ||
kind: ClusterRoleBinding | ||
apiVersion: rbac.authorization.k8s.io/v1 | ||
metadata: | ||
name: namespace-configuration-operator | ||
subjects: | ||
- kind: ServiceAccount | ||
name: namespace-configuration-operator | ||
roleRef: | ||
kind: ClusterRole | ||
name: admin | ||
apiGroup: rbac.authorization.k8s.io | ||
--- | ||
kind: RoleBinding | ||
apiVersion: rbac.authorization.k8s.io/v1 | ||
metadata: | ||
name: namespace-configuration-operator | ||
subjects: | ||
- kind: ServiceAccount | ||
name: namespace-configuration-operator | ||
roleRef: | ||
kind: Role | ||
name: namespace-configuration-operator | ||
apiGroup: rbac.authorization.k8s.io | ||
apiGroup: rbac.authorization.k8s.io |
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,4 +1,4 @@ | ||
// Package v1alpha1 contains API Schema definitions for the redhat-cop v1alpha1 API group | ||
// +k8s:deepcopy-gen=package,register | ||
// +groupName=redhat-cop.io | ||
// +groupName=redhat-cop.redhat.io | ||
package v1alpha1 |
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
Oops, something went wrong.