mirror of
https://github.com/lucky-sideburn/kubeinvaders.git
synced 2026-08-23 21:46:21 +00:00
fix roles
This commit is contained in:
@@ -70,7 +70,7 @@ helm install --set-string target_namespace="namespace1\,namespace2" --name kubei
|
||||
To Install KubeInvaders on your Openshift Cluster clone this repo and launch the following commands:
|
||||
|
||||
```bash
|
||||
oc create clusterrole kubeinvaders-role --verb=watch,get,delete,list --resource=pods
|
||||
oc create clusterrole kubeinvaders-role --verb=watch,get,delete,list --resource=pods,pods/log
|
||||
|
||||
TARGET_NAMESPACE=foobar,awesome-namespace
|
||||
## You can define multiple namespaces ex: TARGET_NAMESPACE=foobar,foobar2
|
||||
@@ -94,28 +94,3 @@ oc process -f openshift/KubeInvaders.yaml -p ROUTE_HOST=$ROUTE_HOST -p TARGET_NA
|
||||
### How the configuration of KubeInvaders DeploymentConfig should be (remember to use your TARGET_NAMESPACE and ROUTE_HOST)
|
||||
|
||||

|
||||
|
||||
### Install KubeInvaders on Kubernetes
|
||||
|
||||
```bash
|
||||
#Change with the namespace you want to stress
|
||||
TARGET_NAMESPACE='foobar'
|
||||
## You can define multiple namespaces ex: TARGET_NAMESPACE=foobar,foobar2
|
||||
|
||||
#Change with the URL of your Kubeinvaders
|
||||
ROUTE_HOST=kubeinvaders.org
|
||||
|
||||
kubectl apply -f kubernetes/kubeinvaders-namespace.yml
|
||||
kubectl apply -f kubernetes/kubeinvaders-deployment.yml -n kubeinvaders
|
||||
kubectl expose deployment kubeinvaders --type=NodePort --name=kubeinvaders -n kubeinvaders --port 8080
|
||||
kubectl apply -f kubernetes/kubeinvaders-ingress.yml -n kubeinvaders
|
||||
kubectl create sa kubeinvaders -n foobar
|
||||
kubectl apply -f kubernetes/kubeinvaders-role.yml
|
||||
kubectl apply -f kubernetes/kubeinvaders-rolebinding.yml
|
||||
|
||||
TOKEN=`kubectl describe secret $(kubectl get secret -n foobar | grep 'kubeinvaders-token' | awk '{ print $1}') -n foobar | grep 'token:' | awk '{ print $2}'`
|
||||
|
||||
kubectl set env deployment/kubeinvaders TOKEN=$TOKEN -n kubeinvaders
|
||||
kubectl set env deployment/kubeinvaders NAMESPACE=$TARGET_NAMESPACE -n kubeinvaders
|
||||
kubectl set env deployment/kubeinvaders ROUTE_HOST=$ROUTE_HOST -n kubeinvaders
|
||||
```
|
||||
|
||||
Binary file not shown.
Executable
+3
@@ -0,0 +1,3 @@
|
||||
apiVersion: v1
|
||||
entries: {}
|
||||
generated: 2020-01-04T08:53:44.106913+01:00
|
||||
@@ -14,6 +14,9 @@ rules:
|
||||
- apiGroups: [""]
|
||||
resources: ["pods"]
|
||||
verbs: ["get", "watch", "list", "delete"]
|
||||
- apiGroups: [""]
|
||||
resources: ["pods/log"]
|
||||
verbs: ["get", "watch", "list"]
|
||||
---
|
||||
kind: RoleBinding
|
||||
apiVersion: rbac.authorization.k8s.io/v1
|
||||
|
||||
Reference in New Issue
Block a user