paramterized additional things and tested on developer sandbox
This commit is contained in:
parent
4018212304
commit
ee31633822
@ -5,6 +5,9 @@ This helm chart can be used on a OpenShift Code Ready Container environment or a
|
|||||||
With the OpenShift CRC (Code Ready Container) cluster you run an entire environment on your local machine. (> 4 vCPU, >8GB mem)
|
With the OpenShift CRC (Code Ready Container) cluster you run an entire environment on your local machine. (> 4 vCPU, >8GB mem)
|
||||||
|
|
||||||
See the Red Hat documentation for general understanding of OpenShift. Make sure helm is installed as well.
|
See the Red Hat documentation for general understanding of OpenShift. Make sure helm is installed as well.
|
||||||
|
|
||||||
|
https://developers.redhat.com/developer-sandbox
|
||||||
|
|
||||||
## CRC commands
|
## CRC commands
|
||||||
|
|
||||||
crc config set cpus 6
|
crc config set cpus 6
|
||||||
@ -22,6 +25,14 @@ The example without modification uses *demo-project* as the project/namespace fo
|
|||||||
|
|
||||||
helm install goat1 ./webgoat
|
helm install goat1 ./webgoat
|
||||||
|
|
||||||
|
## Helm install on single node Developer Sandbox (cloud)
|
||||||
|
|
||||||
|
oc login --token=sha256~phDWy6Wm_oJQW6kmOHEbLkRdDIXU6b70hRVmdSYWolM --server=https://api.sandbox-m2.rz9k.p1.openshiftapps.com:6443
|
||||||
|
helm install --set namespace=renezubcevic-dev --set accessMode=ReadWriteOnce --set urlpostfix=.apps.sandbox-m2.rz9k.p1.openshiftapps.com goat1 ./webgoat
|
||||||
|
|
||||||
|
A code ready container looks the same for all developers on their local machine, but a developer sandbox requires other credentials from your account in the cloud and different namespace and urlpostfix and also a different access mode for the persistent storage.
|
||||||
|
Of course the token here is a fake.
|
||||||
|
|
||||||
## uninstall
|
## uninstall
|
||||||
|
|
||||||
helm uninstall goat1
|
helm uninstall goat1
|
||||||
|
@ -6,4 +6,4 @@ type: application
|
|||||||
|
|
||||||
version: 0.1.0
|
version: 0.1.0
|
||||||
|
|
||||||
appVersion: "openshift"
|
appVersion: "8.2.3-SNAPSHOT"
|
||||||
|
@ -9,5 +9,5 @@ data:
|
|||||||
TZ: 'Europe/Amsterdam'
|
TZ: 'Europe/Amsterdam'
|
||||||
EXCLUDE_CATEGORIES: 'CLIENT_SIDE'
|
EXCLUDE_CATEGORIES: 'CLIENT_SIDE'
|
||||||
EXCLUDE_LESSONS: 'SqlInjectionAdvanced'
|
EXCLUDE_LESSONS: 'SqlInjectionAdvanced'
|
||||||
WEBWOLF_HOST: 'webwolf-1-wolf-demo-project.apps-crc.testing'
|
WEBWOLF_HOST: '{{ .Values.webwolf_server.name }}-wolf-{{ .Values.namespace }}{{ .Values.urlpostfix }}'
|
||||||
WEBWOLF_PORT: '80'
|
WEBWOLF_PORT: '80'
|
||||||
|
@ -56,14 +56,14 @@ spec:
|
|||||||
"--add-opens","java.desktop/java.awt.font=ALL-UNNAMED",
|
"--add-opens","java.desktop/java.awt.font=ALL-UNNAMED",
|
||||||
"--add-opens","java.base/sun.nio.ch=ALL-UNNAMED",
|
"--add-opens","java.base/sun.nio.ch=ALL-UNNAMED",
|
||||||
"--add-opens","java.base/java.io=ALL-UNNAMED",
|
"--add-opens","java.base/java.io=ALL-UNNAMED",
|
||||||
"-Djava.io.tmpdir=/home/webgoat/.webgoat-8.2.3-SNAPSHOT",
|
"-Djava.io.tmpdir=/home/webgoat/.webgoat-{{ .Chart.AppVersion }}",
|
||||||
"-Dfile.encoding=UTF-8",
|
"-Dfile.encoding=UTF-8",
|
||||||
"-jar","/home/webgoat/webgoat.jar",
|
"-jar","/home/webgoat/webgoat.jar",
|
||||||
"--server.address=0.0.0.0"]
|
"--server.address=0.0.0.0"]
|
||||||
imagePullPolicy: Always
|
imagePullPolicy: Always
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
- name: webgoat-volume-1
|
- name: webgoat-volume-1
|
||||||
mountPath: /home/webgoat/.webgoat-8.2.3-SNAPSHOT
|
mountPath: /home/webgoat/.webgoat-{{ .Chart.AppVersion }}
|
||||||
terminationMessagePolicy: File
|
terminationMessagePolicy: File
|
||||||
envFrom:
|
envFrom:
|
||||||
- configMapRef:
|
- configMapRef:
|
||||||
@ -133,14 +133,14 @@ spec:
|
|||||||
command:
|
command:
|
||||||
- 'java'
|
- 'java'
|
||||||
args: ["-Duser.home=/home/webgoat",
|
args: ["-Duser.home=/home/webgoat",
|
||||||
"-Djava.io.tmpdir=/home/webgoat/.webgoat-8.2.3-SNAPSHOT",
|
"-Djava.io.tmpdir=/home/webgoat/.webgoat-{{ .Chart.AppVersion }}",
|
||||||
"-Dfile.encoding=UTF-8",
|
"-Dfile.encoding=UTF-8",
|
||||||
"-jar","/home/webgoat/webwolf.jar",
|
"-jar","/home/webgoat/webwolf.jar",
|
||||||
"--server.address=0.0.0.0"]
|
"--server.address=0.0.0.0"]
|
||||||
imagePullPolicy: Always
|
imagePullPolicy: Always
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
- name: webgoat-volume-1
|
- name: webgoat-volume-1
|
||||||
mountPath: /home/webgoat/.webgoat-8.2.3-SNAPSHOT
|
mountPath: /home/webgoat/.webgoat-{{ .Chart.AppVersion }}
|
||||||
terminationMessagePolicy: File
|
terminationMessagePolicy: File
|
||||||
envFrom:
|
envFrom:
|
||||||
- configMapRef:
|
- configMapRef:
|
||||||
|
@ -5,7 +5,7 @@ metadata:
|
|||||||
namespace: '{{ .Values.namespace }}'
|
namespace: '{{ .Values.namespace }}'
|
||||||
spec:
|
spec:
|
||||||
accessModes:
|
accessModes:
|
||||||
- ReadWriteMany
|
- '{{ .Values.accessMode }}'
|
||||||
resources:
|
resources:
|
||||||
requests:
|
requests:
|
||||||
storage: 1Gi
|
storage: 1Gi
|
||||||
|
@ -1,4 +1,6 @@
|
|||||||
namespace: demo-project
|
namespace: demo-project
|
||||||
|
urlpostfix: .apps-crc.testing
|
||||||
|
accessMode: ReadWriteMany
|
||||||
|
|
||||||
webgoat_server:
|
webgoat_server:
|
||||||
name: webgoat-1
|
name: webgoat-1
|
||||||
@ -7,3 +9,6 @@ webgoat_server:
|
|||||||
webwolf_server:
|
webwolf_server:
|
||||||
name: webwolf-1
|
name: webwolf-1
|
||||||
image: docker.io/webgoat/goatandwolf:openshift
|
image: docker.io/webgoat/goatandwolf:openshift
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user