Skip to content

Commit

Permalink
Merge pull request #10 from lalithkota/main
Browse files Browse the repository at this point in the history
Resolved version conflicts with 1.1.0 branch. Social Registry: Added helm chart. Updated READMEs.
  • Loading branch information
shibu-narayanan authored Feb 9, 2024
2 parents 1fd465c + 272ab79 commit de82328
Show file tree
Hide file tree
Showing 63 changed files with 284 additions and 27 deletions.
2 changes: 1 addition & 1 deletion charts/g2p-cash-transfer-bridge/README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# G2P Cash Transfer Bridge Helm Chart

Refer to [Deployment on Kubernetes](https://docs.openg2p.org/guides/deployment-guide/deployment-on-kubernetes).
Refer to [GCTB Deployment](https://docs.openg2p.org/deployment/openg2p-modules-deployment/gctb-deployment)
18 changes: 18 additions & 0 deletions charts/odk-central/Chart.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
dependencies:
- name: odk-central-mail
repository: ""
version: 1.2.0
- name: odk-central-pyxform
repository: ""
version: 1.2.0
- name: odk-central-enketo
repository: ""
version: 1.2.0
- name: odk-central-backend
repository: ""
version: 1.2.0
- name: odk-central-frontend
repository: ""
version: 1.2.0
digest: sha256:16c0eedfa54001c4fdb86869d87f0bd97b2876021bc6808aec7d00ec54b8211c
generated: "2024-02-09T18:06:14.498165357+05:30"
17 changes: 6 additions & 11 deletions charts/odk-central/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,28 +2,23 @@ apiVersion: v2
name: odk-central
description: A Helm chart for odk-central.
type: application
version: 1.1.0
version: 1.2.0
appVersion: "v2023.1.0"
dependencies:
- name: odk-central-mail
version: 1.1.0
repository: file://charts/odk-mail
version: 1.2.0
condition: odk-central-mail.enabled
- name: odk-central-pyxform
version: 1.1.0
repository: file://charts/odk-pyxform
version: 1.2.0
condition: odk-central-pyxform.enabled
- name: odk-central-enketo
version: 1.1.0
repository: file://charts/odk-enketo
version: 1.2.0
condition: odk-central-enketo.enabled
- name: odk-central-backend
version: 1.1.0
repository: file://charts/odk-backend
version: 1.2.0
condition: odk-central-backend.enabled
- name: odk-central-frontend
version: 1.1.0
repository: file://charts/odk-frontend
version: 1.2.0
condition: odk-central-frontend.enabled
keywords:
- odk
Expand Down
2 changes: 1 addition & 1 deletion charts/odk-central/README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# ODK Central Helm Chart

Refer to [Deployment on Kubernetes](https://docs.openg2p.org/guides/deployment-guide/deployment-on-kubernetes).
Refer to [ODK Central deployment instructions](https://docs.openg2p.org/deployment/external-components-setup/odk-central-deployment)
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: v2
name: odk-central-backend
description: A Helm chart for odk-central-backend.
type: application
version: 0.1.0
version: 1.2.0
appVersion: ""
dependencies:
- name: common
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: v2
name: odk-central-enketo
description: A Helm chart for odk-central-enketo.
type: application
version: 0.1.0
version: 1.2.0
appVersion: ""
dependencies:
- name: common
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: v2
name: odk-central-frontend
description: A Helm chart for odk-central-frontend.
type: application
version: 0.1.0
version: 1.2.0
appVersion: ""
dependencies:
- name: common
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: v2
name: odk-central-mail
description: A Helm chart for odk-central-mail.
type: application
version: 1.1.0
version: 1.2.0
appVersion: ""
dependencies:
- name: common
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: v2
name: odk-central-pyxform
description: A Helm chart for odk-central-pyxform.
type: application
version: 0.1.0
version: 1.2.0
appVersion: ""
dependencies:
- name: common
Expand Down
23 changes: 23 additions & 0 deletions charts/openg2p-social-registry/.helmignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# 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
*.orig
*~
# Various IDEs
.project
.idea/
*.tmproj
.vscode/
6 changes: 6 additions & 0 deletions charts/openg2p-social-registry/Chart.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
dependencies:
- name: odoo
repository: https://charts.bitnami.com/bitnami
version: 21.6.5
digest: sha256:ffd96ae199e3b539f9645efdbc70adb9ee537624df83957074aa40315ae3688a
generated: "2024-02-10T00:02:47.30473352+05:30"
11 changes: 11 additions & 0 deletions charts/openg2p-social-registry/Chart.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
apiVersion: v2
name: openg2p-social-registry
description: A Helm chart for OpenG2P Social Registry Module
type: application
version: 1.2.0
appVersion: "1.2.0"
dependencies:
- name: odoo
repository: https://charts.bitnami.com/bitnami
version: 21.6.5
condition: odoo.enabled
3 changes: 3 additions & 0 deletions charts/openg2p-social-registry/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# OpenG2P Helm Chart

Refer to [Social Registry Deployment](https://docs.openg2p.org/deployment/openg2p-modules-deployment/social-registry-deployment).
Binary file not shown.
51 changes: 51 additions & 0 deletions charts/openg2p-social-registry/templates/_helpers.tpl
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
{{/*
Expand the name of the chart.
*/}}
{{- define "socialRegistry.name" -}}
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" }}
{{- end }}

{{/*
Create a default fully qualified app name.
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
If release name contains chart name it will be used as a full name.
*/}}
{{- define "socialRegistry.fullname" -}}
{{- if .Values.fullnameOverride }}
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" }}
{{- else }}
{{- $name := default .Chart.Name .Values.nameOverride }}
{{- if contains $name .Release.Name }}
{{- .Release.Name | trunc 63 | trimSuffix "-" }}
{{- else }}
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" }}
{{- end }}
{{- end }}
{{- end }}

{{/*
Create chart name and version as used by the chart label.
*/}}
{{- define "socialRegistry.chart" -}}
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }}
{{- end }}

{{/*
Common labels
*/}}
{{- define "socialRegistry.labels" -}}
helm.sh/chart: {{ include "socialRegistry.chart" . }}
{{ include "socialRegistry.selectorLabels" . }}
{{- if .Chart.AppVersion }}
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
{{- end }}
app.kubernetes.io/managed-by: {{ .Release.Service }}
{{- end }}

{{/*
Selector labels
*/}}
{{- define "socialRegistry.selectorLabels" -}}
app.kubernetes.io/name: {{ include "socialRegistry.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
{{- end }}
42 changes: 42 additions & 0 deletions charts/openg2p-social-registry/templates/gateway.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
{{- if .Values.istio.enabled }}
{{- if .Values.istio.gateway.enabled }}
apiVersion: networking.istio.io/v1beta1
kind: Gateway
metadata:
name: {{ include "socialRegistry.fullname" . }}
labels:
{{- include "socialRegistry.labels" . | nindent 4 }}
spec:
selector:
{{ toYaml .Values.istio.gateway.ingressController | nindent 4 }}
servers:
- port:
number: 80
name: http
protocol: HTTP
hosts:
{{- if .Values.istio.gateway.host }}
- {{ .Values.istio.gateway.host }}
{{- else }}
- {{ .Values.global.hostname }}
{{- end }}
{{- if .Values.istio.gateway.httpTlsRedirect }}
tls:
httpsRedirect: true
{{- end }}
- port:
number: 443
name: https
protocol: HTTPS
hosts:
{{- if .Values.istio.gateway.host }}
- {{ .Values.istio.gateway.host }}
{{- else }}
- {{ .Values.global.hostname }}
{{- end }}
{{- if .Values.istio.gateway.tls.enabled }}
tls:
{{ toYaml (omit .Values.istio.gateway.tls "enabled") | nindent 6 }}
{{- end }}
{{- end }}
{{- end }}
34 changes: 34 additions & 0 deletions charts/openg2p-social-registry/templates/virtualservice.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
{{- if .Values.istio.enabled }}
{{- if .Values.istio.virtualservice.enabled }}
apiVersion: networking.istio.io/v1alpha3
kind: VirtualService
metadata:
name: {{ include "socialRegistry.fullname" . }}
labels:
{{- include "socialRegistry.labels" . | nindent 4 }}
spec:
hosts:
{{- if .Values.istio.virtualservice.host }}
- {{ .Values.istio.virtualservice.host }}
{{- else }}
- {{ .Values.global.hostname }}
{{- end }}
gateways:
{{- if not .Values.istio.virtualservice.gateway }}
- {{ include "socialRegistry.fullname" . }}
{{- else }}
- {{ .Values.istio.virtualservice.gateway }}
{{- end }}
http:
- match:
- uri:
exact: /
redirect:
uri: /web
- route:
- destination:
host: {{ include "socialRegistry.fullname" . }}-odoo
port:
number: {{ .Values.odoo.service.port }}
{{- end }}
{{- end }}
72 changes: 72 additions & 0 deletions charts/openg2p-social-registry/values.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
global:
hostname: "openg2p.sandbox.net"

odoo:
image:
repository: openg2p/openg2p-social-registry-odoo-package
tag: "17.0-develop"
pullPolicy: Always

service:
type: ClusterIP
port: 80

odooEmail: admin

postgresql:
enabled: false
# primary:
# extendedConfiguration: |-
# wal_level = logical
# max_wal_senders = 20
# max_replication_slots = 10

externalDatabase:
host: "postgres-postgresql.postgres"
port: 5432
user: openg2puser
database: openg2pdb
create: false
postgresqlPostgresUser: "postgres"
existingSecret: "postgres-postgresql"
existingSecretPasswordKey: "password"
existingSecretPostgresPasswordKey: "postgres-password"

livenessProbe:
enabled: false

extraEnvVars:
- name: ODOO_SKIP_MODULES_UPDATE
value: "yes"
- name: LIMIT_TIME_REAL
value: "5000"
- name: LIST_DB
value: "False"
- name: SERVER_WIDE_MODULES
value: web,queue_job
# not using bitnami smtpHost and smtpPort variables, because they need user and pass as well.
- name: OPENG2P_SMTP_HOST
value: "openg2p-mail.openg2p"
- name: OPENG2P_SMTP_PORT
value: "25"
- name: LOG_HANDLER
value: "[':DEBUG']"
- name: LOG_DB
value: "True"

istio:
enabled: true
virtualservice:
enabled: true
host: ""
gateway: "istio-system/all-hosts"
gateway:
enabled: false
host: ""
ingressController:
istio: ingressgateway
httpTlsRedirect: true
tls:
enabled: true
mode: SIMPLE
credentialName: ""
7 changes: 5 additions & 2 deletions charts/openg2p/Chart.lock
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
dependencies:
- name: odk-central-mail
repository: ""
version: 1.2.0
- name: odoo
repository: https://charts.bitnami.com/bitnami
version: 21.6.5
digest: sha256:ffd96ae199e3b539f9645efdbc70adb9ee537624df83957074aa40315ae3688a
generated: "2022-10-21T14:58:55.205281255+05:30"
digest: sha256:dc3134aaf06e2a987ebaa77d7ce7cd347d5fccf4eff9a8de932fe88e0f7f5715
generated: "2024-02-09T18:02:06.285340237+05:30"
7 changes: 3 additions & 4 deletions charts/openg2p/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,12 @@ apiVersion: v2
name: openg2p
description: A Helm chart for OpenG2P Package
type: application
version: 1.1.0
appVersion: "1.1.0"
version: 1.2.0
appVersion: "1.2.0"
dependencies:
- name: odk-central-mail
alias: mail
version: 1.1.0
repository: file://charts/mail
version: 1.2.0
condition: mail.enabled
- name: odoo
repository: https://charts.bitnami.com/bitnami
Expand Down
2 changes: 1 addition & 1 deletion charts/openg2p/README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# OpenG2P Helm Chart

Refer to [Deployment on Kubernetes](https://docs.openg2p.org/guides/deployment-guide/deployment-on-kubernetes).
Refer to [OpenG2P PBMS deployment instructions](https://docs.openg2p.org/deployment/openg2p-modules-deployment/pbms-deployment)
File renamed without changes.
Loading

0 comments on commit de82328

Please sign in to comment.