Commit 25fec777 authored by Will JALLET's avatar Will JALLET 💸

Base blocks for site binets chart

parent 40529ed9
description: Installation de sites binets
name: sitesbinets
version: v0.1.0
kubeVersion: '>=1.8.0-0'
maintainers:
- name: manifold
- name: konfiot
\ No newline at end of file
# Sites binets
Les templates Helm pour le déploiement de sites sur le cluster.
## Déploiement
```bash
helm install sites-binets --name nomdusite --namespace nomdunamespace
```
{{- define "site.namespace" -}}
{{- if (ne .Release.Namespace "default") -}}
namespace: {{ .Release.Namespace }}
{{- else -}}
namespace: {{ .Release.Name }}
{{- end -}}
{{- end -}}
{{/* Generate basic labels */}}
{{- define "site.labels" -}}
labels:
generator: helm
app: {{ .Release.Name }}-app
version: {{ .Chart.Version }}
{{- end -}}
\ No newline at end of file
---
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
name: creneaux
namespace: creneaux-app
name: {{ .Release.Name }}
{{ template "site.namespace" . }}
{{ template "site.labels" }}
annotations:
flux.weave.works/automated: 'true'
spec:
......@@ -15,8 +16,7 @@ spec:
type: RollingUpdate
template:
metadata:
labels:
app: creneaux-app
{{ template "site.labels" . }}
spec:
containers:
- image: registry.binets.fr/wilson.jallet/creneaux/master:1c2cae462e245ae36c44db8dfb981757cc234951
......
---
{{- if .Values.ingress.enabled -}}
{{- $servicePort := .Values.service.port -}}
apiVersion: extensions/v1beta1
kind: Ingress
metadata:
name: creneaux-app
namespace: creneaux-app
labels:
app: creneaux-app
name: {{ .Release.Name }}
{{ template "site.namespace" . }}
{{ template "site.labels" . }}
spec:
rules:
- host: creneaux.kubeapps.binets.fr
http:
paths:
- backend:
serviceName: creneaux-app
serviceName: {{ .Release.Name }}
servicePort: 5000
{{- end -}}
\ No newline at end of file
---
apiVersion: v1
kind: Service
metadata:
namespace: creneaux-app
name: creneaux-app
labels:
app: creneaux-app
namespace: {{ .Release.Namespace }}
name: {{ .Release.Name }}
{{- template "site.labels" -}}
spec:
type: NodePort
ports:
......
replicaCount: 1
ingress:
enabled: true
hosts:
- kubeapps.binets.fr
service:
port: 8000
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment