Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New version of geonode with configurable probes #49

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from
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
42 changes: 42 additions & 0 deletions charts/geonode/v0.4.2/Chart.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
apiVersion: v2
name: geonode
version: 0.4.1
appVersion: 3.1.0
description: Chart for GeoNode
keywords:
- GeoNode
- GIS
- GeoServer
home: http://geonode.org
sources:
- https://github.com/GeoNode/geonode
maintainers:
- name: lucernae
email: [email protected]
- name: lucernae
email: [email protected]
icon: https://raw.githubusercontent.com/kartoza/charts/master/assets/logo/geonode-logo_for_readme.gif
engine: gotpl
dependencies:
- name: postgis
version: 0.2.1
repository: "file://../../postgis/v0.2.1"
condition: postgis.enabled
tags:
- database-backend
- postgis
- name: geoserver
version: 0.3.1
repository: "file://../../geoserver/v0.3.1"
condition: geoserver.enabled
tags:
- map-backend
- geoserver
- name: rabbitmq
version: 7.6.6
repository: "https://charts.bitnami.com/bitnami"
condition: rabbitmq.enabled
tags:
- broker
- rabbitmq
- amqp
165 changes: 165 additions & 0 deletions charts/geonode/v0.4.2/README.md

Large diffs are not rendered by default.

6 changes: 6 additions & 0 deletions charts/geonode/v0.4.2/app-readme.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# GeoNode

This is Kartoza's GeoNode Rancher charts

GeoNode is a web-based application and platform for developing geospatial information systems (GIS) and for deploying spatial data infrastructures (SDI).

Binary file added charts/geonode/v0.4.2/charts/geoserver-0.3.1.tgz
Binary file not shown.
Binary file added charts/geonode/v0.4.2/charts/postgis-0.2.1.tgz
Binary file not shown.
Binary file added charts/geonode/v0.4.2/charts/rabbitmq-7.6.6.tgz
Binary file not shown.
32 changes: 32 additions & 0 deletions charts/geonode/v0.4.2/ci/celery-async-values.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
---
global:
geonodeSiteName: geonode.test
adminUser: admin
adminPassword:
value: admin
databasePassword:
value: mygeonode
geodatabasePassword:
value: mygeodatabase
geoserverURL: https://geonode.test/geoserver/
geoserverAdminPassword:
value: mygeoserver

ingress:
enabled: true
host: geonode.test
annotations:
cert-manager.io/cluster-issuer: ca-issuer
tls:
enabled: true
secretName: geonode-self-tls

geoserver:
ingress:
enabled: true
host: geonode.test
#annotations:
#cert-manager.io/cluster-issuer: ca-issuer
tls:
enabled: true
secretName: geonode-self-tls
73 changes: 73 additions & 0 deletions charts/geonode/v0.4.2/ci/values.dev.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
---
global:
geonodeSiteName: geonode.test
adminUser: admin
adminPassword:
value: admin
databasePassword:
value: mygeonode
geodatabasePassword:
value: mygeodatabase
# geoserverURL: https://geonode.test/geoserver/
geoserverAdminPassword:
value: mygeoserver
storageClass: longhorn

ingress:
enabled: true
host: geonode.test
annotations:
cert-manager.io/cluster-issuer: ca-issuer
tls:
enabled: true
secretName: geonode-self-tls

extraVolume: |
- name: geonode-code
hostPath:
path: /home/lucernae/WorkingDir/geonode/geonode/scripts

extraVolumeMounts: |
- mountPath: /spcgeonode/scripts
name: geonode-code

# If you want to disable probe: for example, for legacy k8s that doesn't support probe
probe: |
# disable probe

geoserver:
ingress:
enabled: true
host: geonode.test
#annotations:
#cert-manager.io/cluster-issuer: ca-issuer
tls:
enabled: true
secretName: geonode-self-tls


extraVolume: |
- name: config-volume
configMap:
name: {{ template "geoserver.fullname" . }}
defaultMode: 0755
- name: geonode-code
hostPath:
path: /home/lucernae/WorkingDir/geonode/geonode
{{- if .Values.ingress.tls.enabled }}
- name: tls-volume
secret:
secretName: {{ .Values.ingress.tls.secretName | quote }}
{{- end }}

extraVolumeMounts: |
- mountPath: /docker-entrypoint.sh
subPath: docker-entrypoint.sh
name: config-volume
- mountPath: /opt/geonode
name: geonode-code
{{- if .Values.ingress.tls.enabled }}
- mountPath: /tmp/tls-secrets/tls.crt
subPath: tls.crt
name: tls-volume
{{- end }}
34 changes: 34 additions & 0 deletions charts/geonode/v0.4.2/ci/values.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
---
global:
geonodeSiteName: geonode.test
adminUser: admin
adminPassword:
value: admin
databasePassword:
value: mygeonode
geodatabasePassword:
value: mygeodatabase
geoserverURL: https://geonode.test/geoserver/
geoserverAdminPassword:
value: mygeoserver
celeryAsync:
enabled: true

ingress:
enabled: true
host: geonode.test
annotations:
cert-manager.io/cluster-issuer: ca-issuer
tls:
enabled: true
secretName: geonode-self-tls

geoserver:
ingress:
enabled: true
host: geonode.test
#annotations:
#cert-manager.io/cluster-issuer: ca-issuer
tls:
enabled: true
secretName: geonode-self-tls
26 changes: 26 additions & 0 deletions charts/geonode/v0.4.2/templates/NOTES.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
To access GeoNode:

1. Get user and password:

```bash
export GEONODE_ADMIN_USER=$(kubectl get secret --namespace {{ .Release.Namespace }} {{ template "geonode.sharedSecretName" . }} -o jsonpath='{.data.admin-user}' | base64 --decode)
export GEONODE_ADMIN_PASSWORD=$(kubectl get secret --namespace {{ .Release.Namespace }} {{ template "geonode.sharedSecretName" . }} -o jsonpath='{.data.admin-password}' | base64 --decode)
```

{{- if not .Values.ingress.enabled }}
2. You didn't enable ingress, so GeoNode is exposed as Cluster Service by default.

You can arrange access by exposing it to NodePort or external address manually using kubernetes.

Otherwise, you can access it via Kubernetes API-Server proxy:

http://[cluster master address]/api/v1/namespaces/{{ .Release.Namespace }}/services/{{ template "geonode.fullname" . }}:80/proxy/

{{- end }}

{{- if .Values.ingress.enabled }}
2. You have enabled ingress, service will be available here:

http://{{ .Values.ingress.host }}/

{{- end }}
170 changes: 170 additions & 0 deletions charts/geonode/v0.4.2/templates/_geonode-environment.tpl
Original file line number Diff line number Diff line change
@@ -0,0 +1,170 @@
{{/*
This template is used as a shared template generator for GeoNode Django container.

Django, Celery, Celerybeat, and Celerycam containers used by GeoNode all must have
the same environment variables, volume mounts, and pod spec.
The only difference is their labels, command, and entrypoint declarations.
By using a shared template we minimize copy-paste error when modifying the application.
*/}}

{{/*
The GeoNode container spec
*/}}
{{- define "geonode.sharedContainerSpec" -}}
imagePullPolicy: {{ .Values.image.pullPolicy }}
env:
- name: HTTP_HOST
value: {{ .Values.global.geonodeSiteName | quote }}
- name: HTTP_PORT
value: "80"
{{- if .Values.ingress.tls.enabled }}
- name: HTTPS_HOST
value: {{ .Values.global.geonodeSiteName | quote }}
- name: HTTPS_PORT
value: "443"
{{- end }}
- name: ADMIN_USERNAME
value: {{ .Values.global.adminUser | quote }}
- name: ADMIN_PASSWORD
{{- $param := dict "Value" .Values.global.adminPassword "Context" . -}}
{{ include "geonode.secretFrom" $param | nindent 4 }}
- name: ADMIN_EMAIL
value: {{ .Values.global.adminEmail | quote }}
- name: GEOSERVER_ADMIN_USER
value: {{ .Values.global.geoserverAdminUser | quote }}
- name: GEOSERVER_ADMIN_PASSWORD
{{- $param := dict "Value" .Values.global.geoserverAdminPassword "Context" . -}}
{{ include "geonode.secretFrom" $param | nindent 4 }}
- name: REGISTRATION_OPEN
value: "True"
- name: ALLOWED_HOSTS
value: {{ template "geonode.allowedHosts" . }}
- name: SECRET_KEY
{{- $param := dict "Value" .Values.global.djangoSecretKey "Context" . -}}
{{ include "geonode.secretFrom" $param | nindent 4 }}
- name: DEFAULT_BACKEND_UPLOADER
value: "geonode.importer"
- name: DEFAULT_BACKEND_DATASTORE
value: "datastore"
- name: POSTGRES_USER
value: {{ .Values.global.databaseUsername | quote }}
- name: POSTGRES_PASSWORD
{{- $param := dict "Value" .Values.global.databasePassword "Context" . -}}
{{ include "geonode.secretFrom" $param | nindent 4 }}
- name: GEONODE_DATABASE_USER
value: {{ .Values.global.databaseUsername | quote}}
- name: GEONODE_DATABASE
value: {{ .Values.global.databaseName | quote }}
- name: GEONODE_DATABASE_HOST
value: {{ include "geonode.databaseHost" . | quote }}
- name: GEONODE_DATABASE_PORT
value: {{ .Values.global.databasePort | quote }}
- name: GEONODE_DATABASE_PASSWORD
{{- $param := dict "Value" .Values.global.databasePassword "Context" . -}}
{{ include "geonode.secretFrom" $param | nindent 4 }}
- name: GEONODE_GEODATABASE_USER
value: {{ .Values.global.geodatabaseUsername | quote}}
- name: GEONODE_GEODATABASE
value: {{ .Values.global.geodatabaseName | quote }}
- name: GEONODE_GEODATABASE_HOST
value: {{ include "geonode.geodatabaseHost" . | quote }}
- name: GEONODE_GEODATABASE_PORT
value: {{ .Values.global.databasePort | quote }}
- name: GEONODE_GEODATABASE_PASSWORD
{{- $param := dict "Value" .Values.global.geodatabasePassword "Context" . -}}
{{ include "geonode.secretFrom" $param | nindent 4 }}
- name: DEBUG
value: {{ .Values.global.debug | quote }}
- name: DJANGO_SETTINGS_MODULE
value: {{ .Values.global.djangoSettingsModule | quote }}
- name: STATIC_ROOT
value: {{ .Values.global.staticRoot | quote }}
- name: MEDIA_ROOT
value: {{ .Values.global.mediaRoot | quote }}
- name: STATIC_URL
value: "/static/"
- name: MEDIA_URL
value: "/uploaded/"
- name: GEOSERVER_LOCATION
value: {{ include "geonode.internalGeoserverURL" . | quote }}
- name: GEOSERVER_PUBLIC_LOCATION
value: {{ include "geonode.geoserverURL" . | quote }}
- name: SITE_HOST_NAME
value: {{ .Values.global.geonodeSiteName | quote }}
- name: SITEURL
value: {{ include "geonode.siteURL" . | quote }}
{{- if .Values.global.celeryAsync.enabled }}
- name: CELERY_TASK_ALWAYS_EAGER
value: "False"
- name: BROKER_URL
valueFrom:
secretKeyRef:
name: {{ include "geonode.sharedSecretName" . | quote }}
key: broker-url
{{- end }}
{{- with .Values.extraPodEnv }}
{{- tpl . $ | nindent 2 }}
{{- end }}
ports:
- name: uwsgi-geonode
containerPort: 8000
- name: http-geonode
containerPort: 8080
volumeMounts:
- name: config-volume
mountPath: /spcgeonode/geonode/local_settings.py
subPath: local_settings.py
- name: config-volume
mountPath: /spcgeonode/scripts/spcgeonode/django/initialize.py
subPath: initialize.py
{{- if .Values.persistence.staticDir.enabled }}
- name: static-dir
mountPath: {{ .Values.persistence.staticDir.mountPath }}
subPath: {{ .Values.persistence.staticDir.subPath }}
{{- end }}
{{- if .Values.persistence.mediaDir.enabled }}
- name: media-dir
mountPath: {{ .Values.persistence.mediaDir.mountPath }}
subPath: {{ .Values.persistence.mediaDir.subPath }}
{{- end }}
{{- with .Values.extraVolumeMounts }}
{{- (tpl . $) | nindent 2 }}
{{- end }}

{{- end -}}

{{/*
The GeoNode Volume declaration spec
*/}}
{{- define "geonode.sharedVolumeSpec" -}}
volumes:
{{- with .Values.extraVolume }}
{{- (tpl . $) | nindent 2 }}
{{- end }}
- name: config-volume
configMap:
name: {{ template "geonode.fullname" . }}-config
defaultMode: 0755
{{- if and .Values.persistence.staticDir.enabled .Values.persistence.staticDir.existingClaim }}
- name: static-dir
persistentVolumeClaim:
{{- with .Values.persistence.staticDir.existingClaim }}
claimName: {{ tpl . $ }}
{{- end }}
{{- else if .Values.persistence.staticDir.enabled }}
- name: static-dir
persistentVolumeClaim:
claimName: static-dir
{{- end }}
{{- if and .Values.persistence.mediaDir.enabled .Values.persistence.mediaDir.existingClaim }}
- name: media-dir
persistentVolumeClaim:
{{- with .Values.persistence.mediaDir.existingClaim }}
claimName: {{ tpl . $ }}
{{- end }}
{{- else if .Values.persistence.mediaDir.enabled }}
- name: media-dir
persistentVolumeClaim:
claimName: media-dir
{{- end }}
{{- end -}}
Loading