Created
September 28, 2018 20:13
-
-
Save alothings/eff42a3a33834e16cf0321886ec2c826 to your computer and use it in GitHub Desktop.
serviceaccount.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
apiVersion: v1 | |
imagePullSecrets: | |
- name: some-secret | |
kind: ServiceAccount | |
metadata: | |
name: devops-sa | |
namespace: devops | |
---- | |
kind: Role | |
apiVersion: rbac.authorization.k8s.io/v1beta1 | |
metadata: | |
name: jenkins-role | |
namespace: devops | |
rules: | |
- apiGroups: [""] | |
resources: ["pods"] | |
verbs: ["create","delete","get","list","patch","update","watch"] | |
- apiGroups: [""] | |
resources: ["pods/exec"] | |
verbs: ["create","delete","get","list","patch","update","watch"] | |
- apiGroups: [""] | |
resources: ["pods/log"] | |
verbs: ["get","list","watch"] | |
- apiGroups: [""] | |
resources: ["secrets"] | |
verbs: ["get"] | |
---- | |
kind: RoleBinding | |
apiVersion: rbac.authorization.k8s.io/v1 | |
metadata: | |
name: jenkins-role-binding | |
namespace: devops | |
subjects: | |
- kind: ServiceAccount | |
name: devops-sa | |
namespace: devops | |
roleRef: | |
kind: Role | |
name: jenkins-role | |
apiGroup: rbac.authorization.k8s.io |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment