-
Notifications
You must be signed in to change notification settings - Fork 52
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Revert "[MOSIP-35160] deleted admin-ui helm"
This reverts commit 6f9eb15.
- Loading branch information
1 parent
6f9eb15
commit 7995927
Showing
15 changed files
with
890 additions
and
0 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
charts/ |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# Patterns to ignore when building packages. | ||
# This supports shell glob matching, relative path matching, and | ||
# negation (prefixed with !). Only one pattern per line. | ||
.DS_Store | ||
# Common VCS dirs | ||
.git/ | ||
.gitignore | ||
.bzr/ | ||
.bzrignore | ||
.hg/ | ||
.hgignore | ||
.svn/ | ||
# Common backup files | ||
*.swp | ||
*.bak | ||
*.tmp | ||
*~ | ||
# Various IDEs | ||
.project | ||
.idea/ | ||
*.tmproj |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
apiVersion: v2 | ||
name: admin-ui | ||
description: A Helm chart for MOSIP Admin UI module | ||
type: application | ||
version: 0.0.1-develop | ||
appVersion: "" | ||
dependencies: | ||
- name: common | ||
repository: https://charts.bitnami.com/bitnami | ||
tags: | ||
- bitnami-common | ||
version: 1.x.x | ||
home: https://mosip.io | ||
keywords: | ||
- mosip | ||
- admin | ||
- kernel | ||
maintainers: | ||
- email: [email protected] | ||
name: MOSIP |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
# Authmanager | ||
|
||
Helm chart for installing MOSIP Admin UI module | ||
|
||
## TL;DR | ||
|
||
```console | ||
$ helm repo add mosip https://mosip.github.io | ||
$ helm install my-release mosip/admin-ui | ||
``` | ||
|
||
## Prerequisites | ||
|
||
- Kubernetes 1.12+ | ||
- Helm 3.1.0 | ||
- PV provisioner support in the underlying infrastructure | ||
- ReadWriteMany volumes for deployment scaling | ||
|
||
## Installing the Chart | ||
|
||
To install the chart with the release name `admin-ui`. | ||
|
||
```console | ||
helm install my-release mosip/admin-ui | ||
``` | ||
|
||
> **Tip**: List all releases using `helm list` | ||
## Uninstalling the Chart | ||
|
||
To uninstall/delete the `my-release` deployment: | ||
|
||
|
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
|
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
{{/* | ||
Return the proper image name | ||
*/}} | ||
{{- define "admin-ui.image" -}} | ||
{{ include "common.images.image" (dict "imageRoot" .Values.image "global" .Values.global) }} | ||
{{- end -}} | ||
|
||
{{/* | ||
Return the proper image name (for the init container volume-permissions image) | ||
*/}} | ||
{{- define "admin-ui.volumePermissions.image" -}} | ||
{{- include "common.images.image" ( dict "imageRoot" .Values.volumePermissions.image "global" .Values.global ) -}} | ||
{{- end -}} | ||
|
||
{{/* | ||
Return the proper Docker Image Registry Secret Names | ||
*/}} | ||
{{- define "admin-ui.imagePullSecrets" -}} | ||
{{- include "common.images.pullSecrets" (dict "images" (list .Values.image .Values.volumePermissions.image) "global" .Values.global) -}} | ||
{{- end -}} | ||
|
||
{{/* | ||
Create the name of the service account to use | ||
*/}} | ||
{{- define "admin-ui.serviceAccountName" -}} | ||
{{- if .Values.serviceAccount.create -}} | ||
{{ default (printf "%s-foo" (include "common.names.fullname" .)) .Values.serviceAccount.name }} | ||
{{- else -}} | ||
{{ default "default" .Values.serviceAccount.name }} | ||
{{- end -}} | ||
{{- end -}} | ||
|
||
{{/* | ||
Compile all warnings into a single message. | ||
*/}} | ||
{{- define "admin-ui.validateValues" -}} | ||
{{- $messages := list -}} | ||
{{- $messages := append $messages (include "admin-ui.validateValues.foo" .) -}} | ||
{{- $messages := append $messages (include "admin-ui.validateValues.bar" .) -}} | ||
{{- $messages := without $messages "" -}} | ||
{{- $message := join "\n" $messages -}} | ||
|
||
{{- if $message -}} | ||
{{- printf "\nVALUES VALIDATION:\n%s" $message -}} | ||
{{- end -}} | ||
{{- end -}} | ||
|
||
{{/* | ||
Return podAnnotations | ||
*/}} | ||
{{- define "admin-ui.podAnnotations" -}} | ||
{{- if .Values.podAnnotations }} | ||
{{ include "common.tplvalues.render" (dict "value" .Values.podAnnotations "context" $) }} | ||
{{- end }} | ||
{{- if and .Values.metrics.enabled .Values.metrics.podAnnotations }} | ||
{{ include "common.tplvalues.render" (dict "value" .Values.metrics.podAnnotations "context" $) }} | ||
{{- end }} | ||
{{- end -}} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
apiVersion: v1 | ||
kind: ConfigMap | ||
metadata: | ||
name: {{ template "common.names.fullname" . }} | ||
namespace: {{ .Release.Namespace }} | ||
labels: {{- include "common.labels.standard" . | nindent 4 }} | ||
{{- if .Values.commonLabels }} | ||
{{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} | ||
{{- end }} | ||
{{- if .Values.commonAnnotations }} | ||
annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} | ||
{{- end }} | ||
data: | ||
config.json: |- | ||
{"baseUrl":"{{ tpl .Values.admin.apiUrl . }}", "adminUrl" : "/", "primaryLangCode": "eng", "secondaryLangCode": "fra", "validateToken": "authmanager/authorize/admin/validateToken", "login": "admin/login/", "logout": "admin/logout/user", "templateRepoUrl": "/templates/" } | ||
default.conf: |- | ||
server { | ||
listen 8080; | ||
server_name localhost; | ||
add_header X-Frame-Options DENY; | ||
#charset koi8-r; | ||
#access_log /var/log/nginx/host.access.log main; | ||
index index.html index.htm; | ||
location ^~ /templates/ { | ||
if ($uri !~ \.(csv|xlsx)$ ) { return 403; } | ||
autoindex on; | ||
default_type application/octet-stream; | ||
#add_header Content-disposition "attachment; filename=$1"; | ||
index index.html index.php; | ||
alias /usr/share/nginx/html/templates/; | ||
} | ||
location / { | ||
alias /usr/share/nginx/html/; | ||
} | ||
} | ||
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,154 @@ | ||
apiVersion: {{ include "common.capabilities.deployment.apiVersion" . }} | ||
kind: Deployment | ||
metadata: | ||
labels: {{- include "common.labels.standard" . | nindent 4 }} | ||
{{- if .Values.commonLabels }} | ||
{{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} | ||
{{- end }} | ||
name: {{ template "common.names.fullname" . }} | ||
annotations: | ||
{{- if .Values.commonAnnotations }} | ||
{{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} | ||
{{- end }} | ||
spec: | ||
replicas: {{ .Values.replicaCount }} | ||
{{- if .Values.updateStrategy }} | ||
strategy: {{- toYaml .Values.updateStrategy | nindent 4 }} | ||
{{- end }} | ||
selector: | ||
matchLabels: {{- include "common.labels.matchLabels" . | nindent 6 }} | ||
template: | ||
metadata: | ||
annotations: | ||
{{- if or .Values.podAnnotations .Values.metrics.enabled }} | ||
{{- include "admin-ui.podAnnotations" . | nindent 8 }} | ||
{{- end }} | ||
labels: {{- include "common.labels.standard" . | nindent 8 }} | ||
{{- if .Values.podLabels }} | ||
{{- include "common.tplvalues.render" (dict "value" .Values.podLabels "context" $) | nindent 8 }} | ||
{{- end }} | ||
spec: | ||
serviceAccountName: {{ template "admin-ui.serviceAccountName" . }} | ||
{{- include "admin-ui.imagePullSecrets" . | nindent 6 }} | ||
{{- if .Values.hostAliases }} | ||
hostAliases: {{- include "common.tplvalues.render" (dict "value" .Values.hostAliases "context" $) | nindent 8 }} | ||
{{- end }} | ||
{{- if .Values.affinity }} | ||
affinity: {{- include "common.tplvalues.render" ( dict "value" .Values.affinity "context" $) | nindent 8 }} | ||
{{- else }} | ||
affinity: | ||
podAffinity: {{- include "common.affinities.pods" (dict "type" .Values.podAffinityPreset "context" $) | nindent 10 }} | ||
podAntiAffinity: {{- include "common.affinities.pods" (dict "type" .Values.podAntiAffinityPreset "context" $) | nindent 10 }} | ||
nodeAffinity: {{- include "common.affinities.nodes" (dict "type" .Values.nodeAffinityPreset.type "key" .Values.nodeAffinityPreset.key "values" .Values.nodeAffinityPreset.values) | nindent 10 }} | ||
{{- end }} | ||
{{- if .Values.nodeSelector }} | ||
nodeSelector: {{- include "common.tplvalues.render" ( dict "value" .Values.nodeSelector "context" $) | nindent 8 }} | ||
{{- end }} | ||
{{- if .Values.tolerations }} | ||
tolerations: {{- include "common.tplvalues.render" (dict "value" .Values.tolerations "context" .) | nindent 8 }} | ||
{{- end }} | ||
{{- if .Values.priorityClassName }} | ||
priorityClassName: {{ .Values.priorityClassName | quote }} | ||
{{- end }} | ||
{{- if .Values.podSecurityContext.enabled }} | ||
securityContext: {{- omit .Values.podSecurityContext "enabled" | toYaml | nindent 8 }} | ||
{{- end }} | ||
initContainers: | ||
{{- if and .Values.volumePermissions.enabled .Values.persistence.enabled }} | ||
- name: volume-permissions | ||
image: {{ include "admin-ui.volumePermissions.image" . }} | ||
imagePullPolicy: {{ .Values.volumePermissions.image.pullPolicy | quote }} | ||
command: | ||
- %%commands%% | ||
securityContext: | ||
runAsUser: 0 | ||
{{- if .Values.volumePermissions.resources }} | ||
resources: {{- toYaml .Values.volumePermissions.resources | nindent 12 }} | ||
{{- end }} | ||
volumeMounts: | ||
- name: foo | ||
mountPath: bar | ||
{{- end }} | ||
{{- if .Values.initContainers }} | ||
{{- include "common.tplvalues.render" (dict "value" .Values.initContainers "context" $) | nindent 8 }} | ||
{{- end }} | ||
containers: | ||
- name: admin-ui | ||
image: {{ template "admin-ui.image" . }} | ||
imagePullPolicy: {{ .Values.image.pullPolicy }} | ||
{{- if .Values.lifecycleHooks }} | ||
lifecycle: {{- include "common.tplvalues.render" (dict "value" .Values.lifecycleHooks "context" $) | nindent 12 }} | ||
{{- end }} | ||
{{- if .Values.containerSecurityContext.enabled }} | ||
securityContext: {{- omit .Values.containerSecurityContext "enabled" | toYaml | nindent 12 }} | ||
{{- end }} | ||
{{- if .Values.command }} | ||
command: {{- include "common.tplvalues.render" (dict "value" .Values.command "context" $) | nindent 12 }} | ||
{{- end }} | ||
{{- if .Values.args }} | ||
args: {{- include "common.tplvalues.render" (dict "value" .Values.args "context" $) | nindent 12 }} | ||
{{- end }} | ||
env: | ||
- name: container_user | ||
value: {{ .Values.containerSecurityContext.runAsUser }} | ||
- name: JDK_JAVA_OPTIONS | ||
value: {{ .Values.additionalResources.javaOpts }} | ||
{{- if .Values.extraEnvVars }} | ||
{{- include "common.tplvalues.render" (dict "value" .Values.extraEnvVars "context" $) | nindent 12 }} | ||
{{- end }} | ||
envFrom: | ||
{{- if .Values.extraEnvVarsCM }} | ||
{{- range .Values.extraEnvVarsCM }} | ||
- configMapRef: | ||
name: {{ . }} | ||
{{- end }} | ||
{{- end }} | ||
{{- if .Values.extraEnvVarsSecret }} | ||
- secretRef: | ||
name: {{ include "common.tplvalues.render" (dict "value" .Values.extraEnvVarsSecret "context" $) }} | ||
{{- end }} | ||
volumeMounts: | ||
- name: conf-file | ||
mountPath: /usr/share/nginx/html/assets/config.json | ||
subPath: config.json | ||
- name: nginx-config | ||
mountPath: /etc/nginx/conf.d/default.conf | ||
subPath: default.conf | ||
ports: | ||
- name: spring-service | ||
containerPort: {{ .Values.springServicePort }} | ||
{{- if .Values.resources }} | ||
resources: {{- toYaml .Values.resources | nindent 12 }} | ||
{{- end }} | ||
{{- if .Values.startupProbe.enabled }} | ||
startupProbe: {{- include "common.tplvalues.render" (dict "value" (omit .Values.startupProbe "enabled") "context" $) | nindent 12 }} | ||
{{- else if .Values.customStartupProbe }} | ||
startupProbe: {{- include "common.tplvalues.render" (dict "value" .Values.customStartupProbe "context" $) | nindent 12 }} | ||
{{- end }} | ||
{{- if .Values.livenessProbe.enabled }} | ||
livenessProbe: {{- include "common.tplvalues.render" (dict "value" (omit .Values.livenessProbe "enabled") "context" $) | nindent 12 }} | ||
{{- else if .Values.customLivenessProbe }} | ||
livenessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.customLivenessProbe "context" $) | nindent 12 }} | ||
{{- end }} | ||
{{- if .Values.readinessProbe.enabled }} | ||
readinessProbe: {{- include "common.tplvalues.render" (dict "value" (omit .Values.readinessProbe "enabled") "context" $) | nindent 12 }} | ||
{{- else if .Values.customReadinessProbe }} | ||
readinessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.customReadinessProbe "context" $) | nindent 12 }} | ||
{{- end }} | ||
{{- if .Values.sidecars }} | ||
{{- include "common.tplvalues.render" ( dict "value" .Values.sidecars "context" $) | nindent 8 }} | ||
{{- end }} | ||
volumes: | ||
- name: conf-file | ||
configMap: | ||
name: {{ template "common.names.fullname" . }} | ||
items: | ||
- key: config.json | ||
path: config.json | ||
|
||
- name: nginx-config | ||
configMap: | ||
name: {{ template "common.names.fullname" . }} | ||
items: | ||
- key: default.conf | ||
path: default.conf |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{{- range .Values.extraDeploy }} | ||
--- | ||
{{ include "common.tplvalues.render" (dict "value" . "context" $) }} | ||
{{- end }} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
{{- if .Values.istio.enabled }} | ||
apiVersion: networking.istio.io/v1alpha3 | ||
kind: Gateway | ||
metadata: | ||
name: admin-gateway | ||
spec: | ||
selector: | ||
istio: {{ .Values.istio.ingressController.name }} | ||
servers: | ||
- port: | ||
number: 80 | ||
name: http | ||
protocol: HTTP | ||
hosts: | ||
{{- include "common.tplvalues.render" ( dict "value" .Values.istio.hosts "context" $ ) | nindent 6 }} | ||
{{- end }} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
apiVersion: v1 | ||
kind: ServiceAccount | ||
metadata: | ||
labels: {{- include "common.labels.standard" . | nindent 4 }} | ||
{{- if .Values.commonLabels }} | ||
{{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} | ||
{{- end }} | ||
name: {{ template "admin-ui.serviceAccountName" . }} | ||
{{- if .Values.commonAnnotations }} | ||
annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} | ||
{{- end }} | ||
namespace: {{ .Release.Namespace }} |
Oops, something went wrong.