mirror of
https://github.com/lucky-sideburn/kubeinvaders.git
synced 2026-08-23 21:46:21 +00:00
fixed helm chart
This commit is contained in:
@@ -26,16 +26,6 @@ Through KubeInvaders you can stress Kubernetes cluster in a fun way and check ho
|
||||
|
||||
Move the spaceship over a white alien
|
||||
|
||||
### Environment Variables - Make the game more difficult to win!
|
||||
|
||||
Set the following variables in Kubernetes Deployment or Openshift DeploymentConfig
|
||||
|
||||
| ENV Var | Description |
|
||||
|-----------------------------|-------------------------------------------------------------------------------|
|
||||
| ALIENPROXIMITY (default 15) | Reduce the value to increase distance between aliens |
|
||||
| HITSLIMIT (default 0) | Seconds of CPU time to wait before shooting |
|
||||
| UPDATETIME (default 1) | Seconds to wait before update PODs status (you can set also 0.x Es: 0.5) |
|
||||
|
||||
### Install with HELM
|
||||
|
||||
```
|
||||
@@ -46,10 +36,20 @@ kubectl create namespace kubeinvaders
|
||||
|
||||
helm install kubeinvaders --set-string target_namespace="namespace1\,namespace2" \
|
||||
--namespace kubeinvaders ./helm-charts/kubeinvaders \
|
||||
--set ingress.hostname=kubeinvaders.io
|
||||
--set ingress.hostName=kubeinvaders.io
|
||||
|
||||
```
|
||||
|
||||
### Environment Variables - Make the game more difficult to win!
|
||||
|
||||
Set the following variables in Kubernetes Deployment or Openshift DeploymentConfig
|
||||
|
||||
| ENV Var | Description |
|
||||
|-----------------------------|-------------------------------------------------------------------------------|
|
||||
| ALIENPROXIMITY (default 15) | Reduce the value to increase distance between aliens |
|
||||
| HITSLIMIT (default 0) | Seconds of CPU time to wait before shooting |
|
||||
| UPDATETIME (default 1) | Seconds to wait before update PODs status (you can set also 0.x Es: 0.5) |
|
||||
|
||||
### Install client on your workstation
|
||||
|
||||
The easy way to install KubeInvader is run it on you workstation.
|
||||
|
||||
@@ -1,21 +1,4 @@
|
||||
Thank you for installing KubeInvaders!
|
||||
{{- if .Values.ingress.enabled }}
|
||||
{{- range $host := .Values.ingress.hosts }}
|
||||
{{- range .paths }}
|
||||
http{{ if $.Values.ingress.tls }}s{{ end }}://{{ $host.host }}{{ . }}
|
||||
{{- end }}
|
||||
{{- end }}
|
||||
{{- else if contains "NodePort" .Values.service.type }}
|
||||
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "kubeinvaders.fullname" . }})
|
||||
export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
|
||||
echo http://$NODE_IP:$NODE_PORT
|
||||
{{- else if contains "LoadBalancer" .Values.service.type }}
|
||||
NOTE: It may take a few minutes for the LoadBalancer IP to be available.
|
||||
You can watch the status of by running 'kubectl get --namespace {{ .Release.Namespace }} svc -w {{ include "kubeinvaders.fullname" . }}'
|
||||
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "kubeinvaders.fullname" . }} -o jsonpath='{.status.loadBalancer.ingress[0].ip}')
|
||||
echo http://$SERVICE_IP:{{ .Values.service.port }}
|
||||
{{- else if contains "ClusterIP" .Values.service.type }}
|
||||
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "kubeinvaders.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
|
||||
echo "Visit http://127.0.0.1:8080 to use your application"
|
||||
kubectl port-forward $POD_NAME 8080:80
|
||||
Visit http://{{ .Values.ingress.hostName }}
|
||||
{{- end }}
|
||||
|
||||
@@ -22,7 +22,7 @@ spec:
|
||||
containers:
|
||||
- env:
|
||||
- name: ROUTE_HOST
|
||||
value: "{{ .Values.ingress.hostname }}"
|
||||
value: "{{ .Values.ingress.hostName }}"
|
||||
- name: NAMESPACE
|
||||
value: {{ .Values.target_namespace }}
|
||||
- name: TOKEN
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
{{- if .Values.ingress.enabled -}}
|
||||
|
||||
apiVersion: extensions/v1beta1
|
||||
kind: Ingress
|
||||
metadata:
|
||||
@@ -14,13 +16,14 @@ metadata:
|
||||
spec:
|
||||
tls:
|
||||
- hosts:
|
||||
- {{ .Values.ingress.hostname | quote }}
|
||||
- {{ .Values.ingress.hostName | quote }}
|
||||
secretName: {{ .Values.ingress.secretName }}
|
||||
rules:
|
||||
- host: {{ .Values.ingress.hostname }}
|
||||
- host: {{ .Values.ingress.hostName }}
|
||||
http:
|
||||
paths:
|
||||
- path: /
|
||||
backend:
|
||||
serviceName: kubeinvaders
|
||||
servicePort: 8080
|
||||
{{- end }}
|
||||
|
||||
@@ -40,9 +40,9 @@ ingress:
|
||||
enabled: true
|
||||
annotations:
|
||||
nginx.ingress.kubernetes.io/ssl-redirect: "true"
|
||||
hostName:
|
||||
hostName: kubeinvaders.local
|
||||
tls:
|
||||
|
||||
# secretName: kubeinvaders.local
|
||||
|
||||
resources: {}
|
||||
# We usually recommend not to specify default resources and to leave this as a conscious
|
||||
|
||||
Binary file not shown.
Reference in New Issue
Block a user