orangehrm: chart has been accepted into kubernetes/charts repo

This commit is contained in:
Sameer Naik
2017-01-19 09:52:09 +05:30
parent d596640f9c
commit aafe05cb30
14 changed files with 1 additions and 415 deletions

View File

@@ -21,7 +21,7 @@ Popular applications, provided by [Bitnami](https://bitnami.com), ready to launc
- [NodeJS (incubator)](https://github.com/bitnami/charts/tree/master/incubator/node)
- [Odoo (incubator)](https://github.com/bitnami/charts/tree/master/incubator/odoo)
- [OpenCart (stable)](https://github.com/kubernetes/charts/tree/master/stable/opencart)
- [OrangeHRM (incubator)](https://github.com/bitnami/charts/tree/master/incubator/orangehrm)
- [OrangeHRM (incubator)](https://github.com/kubernetes/charts/tree/master/stable/orangehrm)
- [Osclass (incubator)](https://github.com/bitnami/charts/tree/master/incubator/osclass)
- [OwnCloud (stable)](https://github.com/kubernetes/charts/tree/master/stable/owncloud)
- [Parse (incubator)](https://github.com/bitnami/charts/tree/master/incubator/parse)

View File

@@ -1 +0,0 @@
.git

View File

@@ -1,19 +0,0 @@
name: orangehrm
version: 0.4.2
description: OrangeHRM is a free HR management system that offers a wealth of modules to suit the needs of your business.
keywords:
- orangehrm
- http
- https
- web
- application
- php
- human resources
home: https://www.orangehrm.com
sources:
- https://github.com/bitnami/bitnami-docker-orangehrm
maintainers:
- name: Bitnami
email: containers@bitnami.com
engine: gotpl
icon: https://bitnami.com/assets/stacks/orangehrm/img/orangehrm-stack-110x117.png

View File

@@ -1,95 +0,0 @@
# OrangeHRM
[OrangeHRM](https://www.orangehrm.com) is a free HR management system that offers a wealth of modules to suit the needs of your business. This widely-used system is feature-rich, intuitive and provides an essential HR management platform along with free documentation and access to a broad community of users.
## TL;DR;
```console
$ helm install stable/orangehrm
```
## Introduction
This chart bootstraps a [OrangeHRM](https://github.com/bitnami/bitnami-docker-orangehrm) deployment on a [Kubernetes](http://kubernetes.io) cluster using the [Helm](https://helm.sh) package manager.
It also packages the [Bitnami MariaDB chart](https://github.com/kubernetes/charts/tree/master/stable/mariadb) which is required for bootstrapping a MariaDB deployment for the database requirements of the OrangeHRM application.
## Prerequisites
- Kubernetes 1.4+ with Beta APIs enabled
- PV provisioner support in the underlying infrastructure
## Installing the Chart
To install the chart with the release name `my-release`:
```console
$ helm install --name my-release stable/orangehrm
```
The command deploys OrangeHRM on the Kubernetes cluster in the default configuration. The [configuration](#configuration) section lists the parameters that can be configured during installation.
> **Tip**: List all releases using `helm list`
## Uninstalling the Chart
To uninstall/delete the `my-release` deployment:
```console
$ helm delete my-release
```
The command removes all the Kubernetes components associated with the chart and deletes the release.
## Configuration
The following tables lists the configurable parameters of the OrangeHRM chart and their default values.
| Parameter | Description | Default |
|--------------------------------------|------------------------------------------|------------------------------------------------|
| `image` | OrangeHRM image | `bitnami/orangehrm:{VERSION}` |
| `imagePullPolicy` | Image pull policy | `IfNotPresent` |
| `orangehrmUsername` | User of the application | `user` |
| `orangehrmPassword` | Application password | _random 10 character long alphanumeric string_ |
| `smtpHost` | SMTP host | `nil` |
| `smtpPort` | SMTP port | `nil` |
| `smtpUser` | SMTP user | `nil` |
| `smtpPassword` | SMTP password | `nil` |
| `smtpProtocol` | SMTP protocol [`ssl`, `none`] | `nil` |
| `mariadb.mariadbRootPassword` | MariaDB admin password | `nil` |
| `serviceType` | Kubernetes Service type | `LoadBalancer` |
| `persistence.enabled` | Enable persistence using PVC | `true` |
| `persistence.apache.storageClass` | PVC Storage Class for Apache volume | `generic` |
| `persistence.apache.accessMode` | PVC Access Mode for Apache volume | `ReadWriteOnce` |
| `persistence.apache.size` | PVC Storage Request for Apache volume | `1Gi` |
| `persistence.orangehrm.storageClass` | PVC Storage Class for OrangeHRM volume | `generic` |
| `persistence.orangehrm.accessMode` | PVC Access Mode for OrangeHRM volume | `ReadWriteOnce` |
| `persistence.orangehrm.size` | PVC Storage Request for OrangeHRM volume | `8Gi` |
| `resources` | CPU/Memory resource requests/limits | Memory: `512Mi`, CPU: `300m` |
The above parameters map to the env variables defined in [bitnami/orangehrm](http://github.com/bitnami/bitnami-docker-orangehrm). For more information please refer to the [bitnami/orangehrm](http://github.com/bitnami/bitnami-docker-orangehrm) image documentation.
Specify each parameter using the `--set key=value[,key=value]` argument to `helm install`. For example,
```console
$ helm install --name my-release \
--set orangehrmUsername=admin,orangehrmPassword=password,mariadb.mariadbRootPassword=secretpassword \
stable/orangehrm
```
The above command sets the OrangeHRM administrator account username and password to `admin` and `password` respectively. Additionally it sets the MariaDB `root` user password to `secretpassword`.
Alternatively, a YAML file that specifies the values for the above parameters can be provided while installing the chart. For example,
```console
$ helm install --name my-release -f values.yaml stable/orangehrm
```
> **Tip**: You can use the default [values.yaml](values.yaml)
## Persistence
The [Bitnami OrangeHRM](https://github.com/bitnami/bitnami-docker-orangehrm) image stores the OrangeHRM data and configurations at the `/bitnami/orangehrm` and `/bitnami/apache` paths of the container.
Persistent Volume Claims are used to keep the data across deployments. This is known to work in GCE, AWS, and minikube.
See the [Configuration](#configuration) section to configure the PVC or to disable persistence.

View File

@@ -1,6 +0,0 @@
dependencies:
- name: mariadb
repository: https://kubernetes-charts.storage.googleapis.com/
version: 0.5.6
digest: sha256:669140ff8a31fed711c7f5588889edc9c15b4dde5388ead85811b61f8ae5dde9
generated: 2017-01-05T13:17:00.169275967+05:30

View File

@@ -1,4 +0,0 @@
dependencies:
- name: mariadb
version: 0.5.6
repository: https://kubernetes-charts.storage.googleapis.com/

View File

@@ -1,29 +0,0 @@
** Please be patient while the chart is being deployed **
1. Get the OrangeHRM URL by running:
{{- if contains "NodePort" .Values.serviceType }}
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ template "fullname" . }})
export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
echo http://$NODE_IP:$NODE_PORT/
{{- else if contains "LoadBalancer" .Values.serviceType }}
** Please ensure an external IP is associated to the {{ template "fullname" . }} service before proceeding **
** Watch the status using: kubectl get svc --namespace {{ .Release.Namespace }} -w {{ template "fullname" . }} **
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ template "fullname" . }} -o jsonpath='{.status.loadBalancer.ingress[0].ip}')
echo http://$SERVICE_IP/
{{- else if contains "ClusterIP" .Values.serviceType }}
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app={{ template "fullname" . }}" -o jsonpath="{.items[0].metadata.name}")
echo http://127.0.0.1:8080/
kubectl port-forward $POD_NAME 8080:80
{{- end }}
2. Login with the following credentials
echo Username: {{ .Values.orangehrmUsername }}
echo Password: $(printf $(printf '\%o' `kubectl get secret --namespace {{ .Release.Namespace }} {{ template "fullname" . }} -o jsonpath="{.data.orangehrm-password[*]}"`))

View File

@@ -1,24 +0,0 @@
{{/* vim: set filetype=mustache: */}}
{{/*
Expand the name of the chart.
*/}}
{{- define "name" -}}
{{- default .Chart.Name .Values.nameOverride | trunc 24 -}}
{{- end -}}
{{/*
Create a default fully qualified app name.
We truncate at 24 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
*/}}
{{- define "fullname" -}}
{{- $name := default .Chart.Name .Values.nameOverride -}}
{{- printf "%s-%s" .Release.Name $name | trunc 24 -}}
{{- end -}}
{{/*
Create a default fully qualified app name.
We truncate at 24 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
*/}}
{{- define "mariadb.fullname" -}}
{{- printf "%s-%s" .Release.Name "mariadb" | trunc 24 -}}
{{- end -}}

View File

@@ -1,19 +0,0 @@
{{- if .Values.persistence.enabled -}}
kind: PersistentVolumeClaim
apiVersion: v1
metadata:
name: {{ template "fullname" . }}-apache
labels:
app: {{ template "fullname" . }}
chart: "{{ .Chart.Name }}-{{ .Chart.Version }}"
release: "{{ .Release.Name }}"
heritage: "{{ .Release.Service }}"
annotations:
volume.alpha.kubernetes.io/storage-class: {{ .Values.persistence.apache.storageClass | quote }}
spec:
accessModes:
- {{ .Values.persistence.apache.accessMode | quote }}
resources:
requests:
storage: {{ .Values.persistence.apache.size | quote }}
{{- end -}}

View File

@@ -1,88 +0,0 @@
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
name: {{ template "fullname" . }}
labels:
app: {{ template "fullname" . }}
chart: "{{ .Chart.Name }}-{{ .Chart.Version }}"
release: "{{ .Release.Name }}"
heritage: "{{ .Release.Service }}"
spec:
template:
metadata:
labels:
app: {{ template "fullname" . }}
spec:
containers:
- name: {{ template "fullname" . }}
image: "{{ .Values.image }}"
imagePullPolicy: {{ default "" .Values.imagePullPolicy | quote }}
env:
- name: MARIADB_HOST
value: {{ template "mariadb.fullname" . }}
- name: MARIADB_PORT
value: "3306"
- name: MARIADB_PASSWORD
valueFrom:
secretKeyRef:
name: {{ template "mariadb.fullname" . }}
key: mariadb-root-password
- name: ORANGEHRM_USERNAME
value: {{ default "" .Values.orangehrmUsername | quote }}
- name: ORANGEHRM_PASSWORD
valueFrom:
secretKeyRef:
name: {{ template "fullname" . }}
key: orangehrm-password
- name: SMTP_HOST
value: {{ default "" .Values.smtpHost | quote }}
- name: SMTP_PORT
value: {{ default "" .Values.smtpPort | quote }}
- name: SMTP_USER
value: {{ default "" .Values.smtpUser | quote }}
- name: SMTP_PASSWORD
valueFrom:
secretKeyRef:
name: {{ template "fullname" . }}
key: smtp-password
- name: SMTP_PROTOCOL
value: {{ default "none" .Values.smtpProtocol | quote }}
ports:
- name: http
containerPort: 80
- name: https
containerPort: 443
livenessProbe:
httpGet:
path: /
port: http
initialDelaySeconds: 120
timeoutSeconds: 5
readinessProbe:
httpGet:
path: /
port: http
initialDelaySeconds: 5
timeoutSeconds: 1
resources:
{{ toYaml .Values.resources | indent 10 }}
volumeMounts:
- name: orangehrm-data
mountPath: /bitnami/orangehrm
- name: apache-data
mountPath: /bitnami/apache
volumes:
- name: orangehrm-data
{{- if .Values.persistence.enabled }}
persistentVolumeClaim:
claimName: {{ template "fullname" . }}-orangehrm
{{- else }}
emptyDir: {}
{{- end }}
- name: apache-data
{{- if .Values.persistence.enabled }}
persistentVolumeClaim:
claimName: {{ template "fullname" . }}-apache
{{- else }}
emptyDir: {}
{{- end }}

View File

@@ -1,19 +0,0 @@
{{- if .Values.persistence.enabled -}}
kind: PersistentVolumeClaim
apiVersion: v1
metadata:
name: {{ template "fullname" . }}-orangehrm
labels:
app: {{ template "fullname" . }}
chart: "{{ .Chart.Name }}-{{ .Chart.Version }}"
release: "{{ .Release.Name }}"
heritage: "{{ .Release.Service }}"
annotations:
volume.alpha.kubernetes.io/storage-class: {{ .Values.persistence.orangehrm.storageClass | quote }}
spec:
accessModes:
- {{ .Values.persistence.orangehrm.accessMode | quote }}
resources:
requests:
storage: {{ .Values.persistence.orangehrm.size | quote }}
{{- end -}}

View File

@@ -1,17 +0,0 @@
apiVersion: v1
kind: Secret
metadata:
name: {{ template "fullname" . }}
labels:
app: {{ template "fullname" . }}
chart: "{{ .Chart.Name }}-{{ .Chart.Version }}"
release: "{{ .Release.Name }}"
heritage: "{{ .Release.Service }}"
type: Opaque
data:
{{ if .Values.orangehrmPassword }}
orangehrm-password: {{ default "" .Values.orangehrmPassword | b64enc | quote }}
{{ else }}
orangehrm-password: {{ randAlphaNum 10 | b64enc | quote }}
{{ end }}
smtp-password: {{ default "" .Values.smtpPassword | b64enc | quote }}

View File

@@ -1,20 +0,0 @@
apiVersion: v1
kind: Service
metadata:
name: {{ template "fullname" . }}
labels:
app: {{ template "fullname" . }}
chart: "{{ .Chart.Name }}-{{ .Chart.Version }}"
release: "{{ .Release.Name }}"
heritage: "{{ .Release.Service }}"
spec:
type: {{ .Values.serviceType }}
ports:
- name: http
port: 80
targetPort: http
- name: https
port: 443
targetPort: https
selector:
app: {{ template "fullname" . }}

View File

@@ -1,73 +0,0 @@
## Bitnami OrangeHRM image version
## ref: https://hub.docker.com/r/bitnami/orangehrm/tags/
##
image: bitnami/orangehrm:3.3.3-r5
## Specify a imagePullPolicy
## ref: http://kubernetes.io/docs/user-guide/images/#pre-pulling-images
##
imagePullPolicy: IfNotPresent
## User of the application
## ref: https://github.com/bitnami/bitnami-docker-orangehrm#configuration
##
orangehrmUsername: admin
## Application password
## Defaults to a random 10-character alphanumeric string if not set
## ref: https://github.com/bitnami/bitnami-docker-orangehrm#configuration
##
# orangehrmPassword:
## SMTP mail delivery configuration
## ref: https://github.com/bitnami/bitnami-docker-orangehrm/#smtp-configuration
# smtpHost:
# smtpPort:
# smtpUser:
# smtpPassword:
# smtpProtocol:
##
## MariaDB chart configuration
##
mariadb:
## MariaDB admin password
## ref: https://github.com/bitnami/bitnami-docker-mariadb/blob/master/README.md#setting-the-root-password-on-first-run
##
# mariadbRootPassword:
## Enable persistence using Persistent Volume Claims
## ref: http://kubernetes.io/docs/user-guide/persistent-volumes/
##
persistence:
enabled: true
storageClass: generic
accessMode: ReadWriteOnce
size: 8Gi
## Kubernetes configuration
## For minikube, set this to NodePort, elsewhere use LoadBalancer
##
serviceType: LoadBalancer
## Enable persistence using Persistent Volume Claims
## ref: http://kubernetes.io/docs/user-guide/persistent-volumes/
##
persistence:
enabled: true
apache:
storageClass: generic
accessMode: ReadWriteOnce
size: 1Gi
orangehrm:
storageClass: generic
accessMode: ReadWriteOnce
size: 8Gi
## Configure resource requests and limits
## ref: http://kubernetes.io/docs/user-guide/compute-resources/
##
resources:
requests:
memory: 512Mi
cpu: 300m