Skip to content

Commit

Permalink
Merge pull request #5 from restorecommerce/renovate/new-services
Browse files Browse the repository at this point in the history
New Services, Version Bumps
  • Loading branch information
Vilsol authored Oct 20, 2020
2 parents 316a8e0 + 263c621 commit da36c7f
Show file tree
Hide file tree
Showing 95 changed files with 2,785 additions and 239 deletions.
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,20 @@
This repository contains helm charts for the following services:

* [access-control-srv](./charts/access-control-srv)
* [catalog-srv](./charts/catalog-srv)
* [console](./charts/console)
* [fulfillment-srv](./charts/fulfillment-srv)
* [identity-srv](./charts/identity-srv)
* [indexing-srv](./charts/indexing-srv)
* [invoicing-srv](./charts/invoicing-srv)
* [notification-srv](./charts/notification-srv)
* [ordering-srv](./charts/ordering-srv)
* [ostorage-srv](./charts/ostorage-srv)
* [payment-srv](./charts/payment-srv)
* [pdf-rendering-srv](./charts/pdf-rendering-srv)
* [rendering-srv](./charts/rendering-srv)
* [scheduling-srv](./charts/scheduling-srv)
* [store-front](./charts/store-front)
* [system](./charts/system)

## Installation
Expand Down
4 changes: 2 additions & 2 deletions charts/access-control-srv/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ apiVersion: v2
name: access-control-srv
description: A Helm chart for restorecommerce access-control-srv
type: application
version: 0.1.1
appVersion: 0.1.3
version: 0.1.2
appVersion: 0.1.6
icon: https://avatars0.githubusercontent.com/u/8339525
home: https://docs.restorecommerce.io/access-control-srv/index.html
sources:
Expand Down
6 changes: 3 additions & 3 deletions charts/access-control-srv/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# access-control-srv

![Version: 0.1.1](https://img.shields.io/badge/Version-0.1.1-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 0.1.3](https://img.shields.io/badge/AppVersion-0.1.3-informational?style=flat-square)
![Version: 0.1.2](https://img.shields.io/badge/Version-0.1.2-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 0.1.6](https://img.shields.io/badge/AppVersion-0.1.6-informational?style=flat-square)

A Helm chart for restorecommerce access-control-srv

Expand Down Expand Up @@ -32,9 +32,9 @@ A Helm chart for restorecommerce access-control-srv
| env.extras | list | `[]` | Any extra environment variables appended to all pods |
| env.nodeEnv | string | `"production"` | The selected node environment and config |
| fullnameOverride | string | `""` | Full name override for all resources |
| image.pullPolicy | string | `"IfNotPresent"` | Pull policy of the deployment |
| image.pullPolicy | string | `"Always"` | Pull policy of the deployment |
| image.repository | string | `"restorecommerce/access-control-srv"` | Image to be used for deployment |
| image.tag | string | `"0.1.3"` | Image tag |
| image.tag | string | `"0.1.6"` | Image tag |
| imagePullSecrets | list | `[]` | List of secrets for images |
| nameOverride | string | `""` | Name override for all resources |
| nodeSelector | object | `{}` | Specify the nodeSelector for all pods |
Expand Down
13 changes: 6 additions & 7 deletions charts/access-control-srv/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -49,17 +49,16 @@ spec:
periodSeconds: 30
exec:
command:
- sh
- -c
- NODE_OPTIONS=--no-deprecation npm run --silent healthcheck
- /bin/grpc_health_probe
- -addr=:50051
readinessProbe:
initialDelaySeconds: 10
periodSeconds: 30
periodSeconds: 15
exec:
command:
- sh
- -c
- NODE_OPTIONS=--no-deprecation npm run --silent healthcheck
- /bin/grpc_health_probe
- -addr=:50051
- -service=readiness
resources:
{{- toYaml .Values.resources | nindent 12 }}
{{- if or .Values.config.name .Values.config.literal }}
Expand Down
4 changes: 2 additions & 2 deletions charts/access-control-srv/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@ image:
repository: restorecommerce/access-control-srv

# image.pullPolicy -- Pull policy of the deployment
pullPolicy: IfNotPresent
pullPolicy: Always

# image.tag -- Image tag
tag: 0.1.3
tag: 0.1.6

# imagePullSecrets -- List of secrets for images
imagePullSecrets: []
Expand Down
23 changes: 23 additions & 0 deletions charts/catalog-srv/.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/
14 changes: 14 additions & 0 deletions charts/catalog-srv/Chart.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
apiVersion: v2
name: catalog-srv
description: A Helm chart for restorecommerce catalog-srv
type: application
version: 0.1.0
appVersion: 0.0.3
icon: https://avatars0.githubusercontent.com/u/8339525
home: https://docs.restorecommerce.io/catalog-srv/index.html
sources:
- https://github.com/restorecommerce/catalog-srv
maintainers:
- name: restorecommerce
url: https://restorecommerce.io/
email: [email protected]
51 changes: 51 additions & 0 deletions charts/catalog-srv/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
# catalog-srv

![Version: 0.1.0](https://img.shields.io/badge/Version-0.1.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 0.0.3](https://img.shields.io/badge/AppVersion-0.0.3-informational?style=flat-square)

A Helm chart for restorecommerce catalog-srv

**Homepage:** <https://docs.restorecommerce.io/catalog-srv/index.html>

## Maintainers

| Name | Email | Url |
| ---- | ------ | --- |
| restorecommerce | [email protected] | https://restorecommerce.io/ |

## Source Code

* <https://github.com/restorecommerce/catalog-srv>

## Values

| Key | Type | Default | Description |
|-----|------|---------|-------------|
| affinity | object | `{}` | Specify the affinity for all pods |
| autoscaling.enabled | bool | `false` | Enable HPA |
| autoscaling.maxReplicas | int | `100` | Max amount of replicas for HPA |
| autoscaling.minReplicas | int | `1` | Min amount of replicas for HPA |
| autoscaling.targetCPUUtilizationPercentage | int | `80` | Target CPU usage for HPA |
| autoscaling.targetMemoryUtilizationPercentage | int | `80` | Target memory usage for HPA |
| config.file | string | `"config_production_override.json"` | Name of the file in the config map |
| config.literal | string | `""` | Provide the literal config through this string. Has to be in a JSON format |
| config.name | string | `""` | Name of the config map to be mounted. If specified, config will be appended to the node environment automatically |
| env.extras | list | `[]` | Any extra environment variables appended to all pods |
| env.nodeEnv | string | `"production"` | The selected node environment and config |
| fullnameOverride | string | `""` | Full name override for all resources |
| image.pullPolicy | string | `"Always"` | Pull policy of the deployment |
| image.repository | string | `"restorecommerce/catalog-srv"` | Image to be used for deployment |
| image.tag | string | `"0.0.3"` | Image tag |
| imagePullSecrets | list | `[]` | List of secrets for images |
| nameOverride | string | `""` | Name override for all resources |
| nodeSelector | object | `{}` | Specify the nodeSelector for all pods |
| podAnnotations | object | `{}` | Any extra annotations for all pods |
| podSecurityContext | object | `{}` | Security context override for all pods |
| replicaCount | int | `1` | Replica count of the deployment |
| resources | object | `{}` | Any resource configuration applied to all pods |
| securityContext | object | `{}` | Security context override for all containers |
| service.port | int | `50051` | Port to be exposed on the service |
| service.type | string | `"ClusterIP"` | Service type to be used |
| serviceAccount.annotations | object | `{}` | Annotations to add to the service account |
| serviceAccount.create | bool | `true` | Specifies whether a service account should be created |
| serviceAccount.name | string | `""` | The name of the service account to use. If not set and serviceAccount.create is true, a name is generated using the fullname template |
| tolerations | list | `[]` | Specify the tolerations for all pods |
76 changes: 76 additions & 0 deletions charts/catalog-srv/templates/_helpers.tpl
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
{{/* vim: set filetype=mustache: */}}
{{/*
Expand the name of the chart.
*/}}
{{- define "catalog-srv.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 "catalog-srv.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 "catalog-srv.chart" -}}
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }}
{{- end }}

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

{{/*
Selector labels
*/}}
{{- define "catalog-srv.selectorLabels" -}}
app.kubernetes.io/name: {{ include "catalog-srv.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
{{- end }}

{{/*
Create the name of the service account to use
*/}}
{{- define "catalog-srv.serviceAccountName" -}}
{{- if .Values.serviceAccount.create }}
{{- default (include "catalog-srv.fullname" .) .Values.serviceAccount.name }}
{{- else }}
{{- default "default" .Values.serviceAccount.name }}
{{- end }}
{{- end }}

{{/*
Create the NODE_ENV variable.
*/}}
{{- define "catalog-srv.nodeEnv" -}}
{{- if .Values.config.name }}
{{- printf "%s:%s" .Values.env.nodeEnv (.Values.config.file | trimPrefix (printf "config_%s_" .Values.env.nodeEnv) | trimSuffix ".json") }}
{{- else if .Values.config.literal }}
{{- printf "%s:override" .Values.env.nodeEnv }}
{{- else }}
{{- printf "%s" .Values.env.nodeEnv }}
{{- end }}
{{- end }}
10 changes: 10 additions & 0 deletions charts/catalog-srv/templates/configmap.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{{- if .Values.config.literal }}
apiVersion: v1
kind: ConfigMap
metadata:
name: "{{ include "catalog-srv.fullname" . }}-config"
labels:
{{- include "catalog-srv.labels" . | nindent 4 }}
data:
config_production_override.json: {{ .Values.config.literal | quote }}
{{- end }}
92 changes: 92 additions & 0 deletions charts/catalog-srv/templates/deployment.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,92 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: {{ include "catalog-srv.fullname" . }}
labels:
{{- include "catalog-srv.labels" . | nindent 4 }}
spec:
{{- if not .Values.autoscaling.enabled }}
replicas: {{ .Values.replicaCount }}
{{- end }}
selector:
matchLabels:
{{- include "catalog-srv.selectorLabels" . | nindent 6 }}
template:
metadata:
annotations:
checksum/config: {{ include (print $.Template.BasePath "/configmap.yaml") . | sha256sum }}
{{- with .Values.podAnnotations }}
{{- toYaml . | nindent 8 }}
{{- end }}
labels:
{{- include "catalog-srv.selectorLabels" . | nindent 8 }}
spec:
{{- with .Values.imagePullSecrets }}
imagePullSecrets:
{{- toYaml . | nindent 8 }}
{{- end }}
serviceAccountName: {{ include "catalog-srv.serviceAccountName" . }}
securityContext:
{{- toYaml .Values.podSecurityContext | nindent 8 }}
containers:
- name: {{ .Chart.Name }}
securityContext:
{{- toYaml .Values.securityContext | nindent 12 }}
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
imagePullPolicy: {{ .Values.image.pullPolicy }}
ports:
- name: grpc
containerPort: 50051
protocol: TCP
env:
- name: NODE_ENV
value: {{ include "catalog-srv.nodeEnv" . }}
{{- if .Values.env.extras }}
{{- toYaml .Values.env.extras | nindent 12 }}
{{- end }}
livenessProbe:
initialDelaySeconds: 10
periodSeconds: 30
exec:
command:
- /bin/grpc_health_probe
- -addr=:50051
readinessProbe:
initialDelaySeconds: 10
periodSeconds: 15
exec:
command:
- /bin/grpc_health_probe
- -addr=:50051
- -service=readiness
resources:
{{- toYaml .Values.resources | nindent 12 }}
{{- if or .Values.config.name .Values.config.literal }}
volumeMounts:
- name: config
mountPath: "/home/node/catalog-srv/cfg/config_{{ .Values.env.nodeEnv }}_override.json"
subPath: {{ .Values.config.file | quote }}
{{- end }}
{{- with .Values.nodeSelector }}
nodeSelector:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.affinity }}
affinity:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.tolerations }}
tolerations:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- if or .Values.config.name .Values.config.literal }}
volumes:
- name: config
configMap:
{{- with .Values.config.name }}
name: {{ . | quote }}
{{- end }}
{{- if .Values.config.literal }}
name: "{{ include "catalog-srv.fullname" . }}-config"
{{- end }}
{{- end }}
28 changes: 28 additions & 0 deletions charts/catalog-srv/templates/hpa.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
{{- if .Values.autoscaling.enabled }}
apiVersion: autoscaling/v2beta1
kind: HorizontalPodAutoscaler
metadata:
name: {{ include "catalog-srv.fullname" . }}
labels:
{{- include "catalog-srv.labels" . | nindent 4 }}
spec:
scaleTargetRef:
apiVersion: apps/v1
kind: Deployment
name: {{ include "catalog-srv.fullname" . }}
minReplicas: {{ .Values.autoscaling.minReplicas }}
maxReplicas: {{ .Values.autoscaling.maxReplicas }}
metrics:
{{- if .Values.autoscaling.targetCPUUtilizationPercentage }}
- type: Resource
resource:
name: cpu
targetAverageUtilization: {{ .Values.autoscaling.targetCPUUtilizationPercentage }}
{{- end }}
{{- if .Values.autoscaling.targetMemoryUtilizationPercentage }}
- type: Resource
resource:
name: memory
targetAverageUtilization: {{ .Values.autoscaling.targetMemoryUtilizationPercentage }}
{{- end }}
{{- end }}
Loading

0 comments on commit da36c7f

Please sign in to comment.