Skip to content

Instantly share code, notes, and snippets.

@roock
Last active November 5, 2020 14:00
Show Gist options
  • Save roock/86a4a7c4380c079912d61816138ef3bd to your computer and use it in GitHub Desktop.
Save roock/86a4a7c4380c079912d61816138ef3bd to your computer and use it in GitHub Desktop.
apiVersion: v1
kind: ConfigMap
metadata:
name: configmap-test
annotations:
replicator.v1.mittwald.de/replicate-to: "roock,roman"
data:
test_data: "3"
apiVersion: rbac.authorization.k8s.io/v1beta1
kind: Role
metadata:
name: list-deployments
annotations:
replicator.v1.mittwald.de/replicate-to: "roock,roman"
rules:
- apiGroups: [ apps ]
resources: [ deployments ]
verbs: [ get, list ]
apiVersion: rbac.authorization.k8s.io/v1
kind: Role
metadata:
name: pod-reader
namespace: default
annotations:
replicator.v1.mittwald.de/replicate-to: "roock,roman"
rules:
- apiGroups: [""] # "" indicates the core API group
resources: ["pods"]
verbs: ["get", "watch", "list"]
kind: Role
apiVersion: rbac.authorization.k8s.io/v1beta1
metadata:
annotations:
replicator.v1.mittwald.de/replicate-to: "roock,roman"
name: developers-role
rules:
- apiGroups: ["","apps","batch","extensions"]
resources:
- "configmaps"
- "cronjobs"
- "deployments"
- "events"
- "ingresses"
- "jobs"
- "pods"
- "pods/attach"
- "pods/exec"
- "pods/log"
- "pods/portforward"
- "services"
verbs:
- "create"
- "delete"
- "describe"
- "get"
- "list"
- "patch"
- "update"
apiVersion: rbac.authorization.k8s.io/v1
kind: RoleBinding
metadata:
annotations:
replicator.v1.mittwald.de/replicate-to: "roock,roman"
name: developer-RoleBinding
roleRef:
apiGroup: rbac.authorization.k8s.io
kind: Role
name: developers-role
subjects:
- apiGroup: rbac.authorization.k8s.io
kind: Group
name: developers
args:
- -log-level=trace
- -resync-period=1m
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment