Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions wproofreader/templates/NOTES.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
WProofreader Server has been deployed successfully!
{{- $baseUrl := printf "http%s://%s.%s.svc:%s/%s/" (.Values.useHTTPS | ternary "s" "") (include "wproofreader.fullname" .)
.Release.Namespace (include "wproofreader.servicePort" . | toString) .Values.virtualDir
{{- $baseUrl := printf "http%s://%s.%s.svc:%s%s/" (.Values.useHTTPS | ternary "s" "") (include "wproofreader.fullname" .)
.Release.Namespace (include "wproofreader.servicePort" . | toString) (include "wproofreader.virtualDirBasePath" .)
}}
Quick start:
{{ print $baseUrl }}
Expand Down
9 changes: 9 additions & 0 deletions wproofreader/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,15 @@ Insert key/cert pair from file.
{{- template "wproofreader.printKeyValue" (dict (last $cert_path) $cert (last $key_path) $key) }}
{{- end }}

{{/*
Returns virtualDir as a path prefix: "/wscservice" for "wscservice", or "" for "/" or "".
Append your path directly: {{ include "wproofreader.virtualDirBasePath" . }}/api?cmd=status
*/}}
{{- define "wproofreader.virtualDirBasePath" -}}
{{- $vd := .Values.virtualDir | trimAll "/" -}}
{{- if $vd -}}{{- printf "/%s" $vd -}}{{- end -}}
{{- end }}

{{/*
Returns default web port as an integer.
*/}}
Expand Down
4 changes: 2 additions & 2 deletions wproofreader/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -44,15 +44,15 @@ spec:
protocol: TCP
livenessProbe:
httpGet:
path: /{{ .Values.virtualDir }}
path: {{ include "wproofreader.virtualDirBasePath" . }}/
port: container-port
scheme: {{ if .Values.useHTTPS }}HTTPS{{ else }}HTTP{{ end }}
{{- with .Values.livenessProbeOptions }}
{{- toYaml . | nindent 12 }}
{{- end }}
readinessProbe:
httpGet:
path: "/{{ .Values.virtualDir }}/api?cmd=status"
path: "{{ include "wproofreader.virtualDirBasePath" . }}/api?cmd=status"
port: container-port
scheme: {{ if .Values.useHTTPS }}HTTPS{{ else }}HTTP{{ end }}
{{- with .Values.readinessProbeOptions }}
Expand Down
4 changes: 2 additions & 2 deletions wproofreader/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ licenseTicketID: ""
# extra environment variables to pass to the container
extraEnv: []
# extraEnv:
# - name: WPR_DOMAIN_NAME
# value: "wproofreader.domain-name.com"
# - name: WPR_JVM_MAX_MEMORY_SIZE_MB
# value: "2048"

# directory of the service for web and API requests, e.g. http://localhost/wscservice/api?cmd=ver
virtualDir: wscservice
Expand Down