Skip to content

Commit 791a561

Browse files
committed
Release prerender 1.0.1
1 parent ad49ce7 commit 791a561

File tree

7 files changed

+167
-10
lines changed

7 files changed

+167
-10
lines changed

docs/index.yaml

+37-1
Original file line numberDiff line numberDiff line change
@@ -477,6 +477,42 @@ entries:
477477
- https://utkuozdemir.org/helm-charts/plex-0.1.0.tgz
478478
version: 0.1.0
479479
prerender:
480+
- annotations:
481+
artifacthub.io/changes: |
482+
- Add README
483+
- Allow environment variables to be set
484+
- Bump appVersion to 6.3.0
485+
- Change autoscaling.maxReplicas default to 10
486+
artifacthub.io/images: |
487+
- name: tvanro/prerender-alpine
488+
image: docker.io/tvanro/prerender-alpine:6.2.0
489+
artifacthub.io/license: MIT
490+
apiVersion: v2
491+
appVersion: 6.3.0
492+
created: "2021-03-13T17:21:58.433135+01:00"
493+
description: Helm chart for prerender wrapping tvanro/prerender-alpine
494+
digest: a698bf6a9126e0af41a61dae2aa88b12945bfb744082d4071cfc3379aca77fa8
495+
home: https://github.com/prerender/prerender
496+
icon: https://utkuozdemir.org/helm-charts/prerender.png
497+
keywords:
498+
- prerender
499+
- render
500+
- chrome
501+
- headless-chrome
502+
- tvanro
503+
maintainers:
504+
505+
name: Utku Özdemir
506+
url: https://utkuozdemir.org
507+
name: prerender
508+
sources:
509+
- https://github.com/prerender/prerender
510+
- https://github.com/tvanro/prerender-alpine
511+
- https://github.com/utkuozdemir/helm-charts
512+
type: application
513+
urls:
514+
- https://utkuozdemir.org/helm-charts/prerender-1.0.1.tgz
515+
version: 1.0.1
480516
- annotations:
481517
artifacthub.io/changes: |
482518
- Initial release
@@ -631,4 +667,4 @@ entries:
631667
urls:
632668
- https://utkuozdemir.org/helm-charts/transmission-openvpn-0.1.0.tgz
633669
version: 0.1.0
634-
generated: "2021-03-12T01:23:29.927045+01:00"
670+
generated: "2021-03-13T17:21:58.430335+01:00"

docs/prerender-1.0.1.tgz

5.12 KB
Binary file not shown.

prerender/Chart.yaml

+6-3
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@ apiVersion: v2
22
name: prerender
33
description: Helm chart for prerender wrapping tvanro/prerender-alpine
44
type: application
5-
version: 1.0.0
6-
appVersion: 6.2.0
5+
version: 1.0.1
6+
appVersion: 6.3.0
77
home: https://github.com/prerender/prerender
88
keywords:
99
- prerender
@@ -23,7 +23,10 @@ maintainers:
2323
annotations:
2424
artifacthub.io/license: MIT
2525
artifacthub.io/changes: |
26-
- Initial release
26+
- Add README
27+
- Allow environment variables to be set
28+
- Bump appVersion to 6.3.0
29+
- Change autoscaling.maxReplicas default to 10
2730
artifacthub.io/images: |
2831
- name: tvanro/prerender-alpine
2932
image: docker.io/tvanro/prerender-alpine:6.2.0

prerender/README.md

+102-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,104 @@
11
# prerender
22

3-
TODO
3+
[Prerender](https://github.com/prerender/prerender) Prerender is a node server that uses
4+
Headless Chrome to render HTML, screenshots, PDFs, and HAR files out of any web page.
5+
6+
## TL;DR
7+
8+
```console
9+
$ helm repo add utkuozdemir https://utkuozdemir.org/helm-charts
10+
$ helm install my-release utkuozdemir/prerender
11+
```
12+
13+
## Introduction
14+
15+
This Helm chart simply wraps the Docker image
16+
[tvanro/prerender-alpine](https://github.com/tvanro/prerender-alpine).
17+
18+
## Prerequisites
19+
20+
- Kubernetes 1.15+
21+
- Helm 3.0+
22+
23+
## Installing the Chart
24+
25+
To install the chart with the release name `my-release`:
26+
27+
```console
28+
$ helm repo add utkuozdemir https://utkuozdemir.org/helm-charts
29+
$ helm install my-release utkuozdemir/prerender
30+
```
31+
32+
These commands deploy prerender in the default configuration.
33+
The [Parameters](#parameters) section lists the parameters
34+
that can be configured during installation.
35+
36+
> **Tip**: List all releases using `helm list`
37+
38+
## Uninstalling the Chart
39+
40+
To uninstall/delete the `my-release` release:
41+
42+
```console
43+
$ helm delete my-release
44+
```
45+
46+
The command removes all the Kubernetes components associated with the chart and deletes the release.
47+
48+
## Parameters
49+
50+
| Key | Description | Default |
51+
|-----|------|---------|
52+
| `image.repository` | Image repository | `"prerender/prerender-single-process"` |
53+
| `image.pullPolicy` | Image pull policy | `"IfNotPresent"` |
54+
| `image.tag` | Image tag (if not specified, defaults to the chart's appVersion) | `""` |
55+
| `imagePullSecrets` | Image pull secrets | `[]` |
56+
| `nameOverride` | String to partially override prerender.fullname template with a string (will prepend the release name) | `""` |
57+
| `fullnameOverride` | String to fully override prerender.fullname template with a string | `""` |
58+
| `serviceAccount.create` | Create a service account | `true` |
59+
| `serviceAccount.annotations` | Annotations for the service account | `{}` |
60+
| `serviceAccount.name` | The name of the service account to create | `""` |
61+
| `service.type` | Type of the service | `"ClusterIP"` |
62+
| `service.annotations` | Annotations for the service | `{}` |
63+
| `ingress.enabled` | Enable the use of the ingress controller | `false` |
64+
| `ingress.annotations` | Annotations for the Ingress | `{}` |
65+
| `ingress.hosts[0].host` | Hostname to your installation | `chart-example.local` |
66+
| `ingress.hosts[0].paths` | Path within the url structure | `[]` |
67+
| `ingress.tls` | The TLS configuration for the ingress | `[]` |
68+
| `replicaCount` | Pod replica count (if autoscaling is not enabled) | `1` |
69+
| `autoscaling.enabled` | Enable autoscaling | `false` |
70+
| `autoscaling.minReplicas` | Minimum number of replicas when autoscaling is enabled | `1` |
71+
| `autoscaling.maxReplicas` | Maximum number of replicas when autoscaling is enabled | `10` |
72+
| `autoscaling.targetCPUUtilizationPercentage` | Target CPU utilization percentage when autoscaling is enabled | `80` |
73+
| `autoscaling.targetMemoryUtilizationPercentage` | Target memory utilization percentage when autoscaling is enabled | `nil`
74+
| `resources` | The resource requests and limits of the container | `{}` |
75+
| `podAnnotations` | Annotations for the pod | `{}` |
76+
| `podSecurityContext` | Security context for the pod | `{}` |
77+
| `securityContext` | Security context for the container | `{}` |
78+
| `nodeSelector` | The node selector for the deployment | `{}` |
79+
| `tolerations` | Tolerations for the pod assignment | `[]` |
80+
| `affinity` | Affinity for the pod assignment | `{}` |
81+
| `env` | The env variable key-value pairs to be passed to the pod | `{"NODE_ENV":"production"}` |
82+
83+
The above config parameters map to the various configuration env variables of a typical prerender server.
84+
85+
For more information please refer to the
86+
[project repository](https://github.com/prerender/prerender)
87+
and the [Docker image project repository](https://github.com/tvanro/prerender-alpine).
88+
89+
Specify each parameter using the `--set key=value[,key=value]` argument to `helm install`. For example,
90+
91+
```console
92+
helm install my-release \
93+
--set env.CACHE_MAXSIZE=2000 \
94+
utkuozdemir/prerender
95+
```
96+
97+
Alternatively, a YAML file that specifies the values for the above parameters
98+
can be provided while installing the chart. For example,
99+
100+
```console
101+
helm install my-release -f values.yaml utkuozdemir/prerender
102+
```
103+
104+
> **Tip**: You can use the default [values.yaml](values.yaml)

prerender/templates/configmap.yaml

+10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
apiVersion: v1
2+
kind: ConfigMap
3+
metadata:
4+
name: {{ include "prerender.fullname" . }}
5+
labels:
6+
{{- include "prerender.labels" . | nindent 4 }}
7+
data:
8+
{{- range $k, $v := .Values.env }}
9+
{{ $k }}: {{ $v | quote }}
10+
{{- end }}

prerender/templates/deployment.yaml

+5-4
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,9 @@ spec:
1313
{{- include "prerender.selectorLabels" . | nindent 6 }}
1414
template:
1515
metadata:
16-
{{- with .Values.podAnnotations }}
1716
annotations:
17+
checksum/configmap: {{ include (print $.Template.BasePath "/configmap.yaml") . | sha256sum }}
18+
{{- with .Values.podAnnotations }}
1819
{{- toYaml . | nindent 8 }}
1920
{{- end }}
2021
labels:
@@ -29,9 +30,9 @@ spec:
2930
{{- toYaml .Values.podSecurityContext | nindent 8 }}
3031
containers:
3132
- name: {{ .Chart.Name }}
32-
env:
33-
- name: NODE_ENV
34-
value: production
33+
envFrom:
34+
- configMapRef:
35+
name: {{ include "prerender.fullname" . }}
3536
securityContext:
3637
{{- toYaml .Values.securityContext | nindent 12 }}
3738
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"

prerender/values.yaml

+7-1
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ resources: {}
6868
autoscaling:
6969
enabled: false
7070
minReplicas: 1
71-
maxReplicas: 100
71+
maxReplicas: 10
7272
targetCPUUtilizationPercentage: 80
7373
# targetMemoryUtilizationPercentage: 80
7474

@@ -77,3 +77,9 @@ nodeSelector: {}
7777
tolerations: []
7878

7979
affinity: {}
80+
81+
env:
82+
NODE_ENV: production
83+
# MEMORY_CACHE: "1"
84+
# CACHE_MAXSIZE: "1000"
85+
# CACHE_TTL: "6000"

0 commit comments

Comments
 (0)