Last active
March 19, 2020 12:22
-
-
Save surajssd/8bb92f2a2489fd5ce70fa37be89efdf7 to your computer and use it in GitHub Desktop.
A deployment that fails constantly
This file contains hidden or 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
echo ' | |
apiVersion: apps/v1 | |
kind: Deployment | |
metadata: | |
labels: | |
run: bash | |
name: bash | |
spec: | |
replicas: 1 | |
selector: | |
matchLabels: | |
run: bash | |
template: | |
metadata: | |
labels: | |
run: bash | |
spec: | |
containers: | |
- image: debian | |
name: bash | |
command: ["/bin/sh"] | |
args: ["-c", "sleep 5 && exit 1"] | |
' | k apply -f - |
This file contains hidden or 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
echo ' | |
apiVersion: rbac.authorization.k8s.io/v1 | |
kind: RoleBinding | |
metadata: | |
name: privileged-psp-default | |
namespace: default | |
roleRef: | |
apiGroup: rbac.authorization.k8s.io | |
kind: ClusterRole | |
name: privileged-psp | |
subjects: | |
- apiGroup: rbac.authorization.k8s.io | |
kind: Group | |
name: system:serviceaccounts:default | |
' | k apply -f - |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment