This commit is contained in:
Waloshi6
2026-01-27 17:34:16 +01:00
parent 4c3bd195b7
commit c8204829e9
237 changed files with 3542 additions and 1737 deletions

View File

@@ -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/

View File

@@ -0,0 +1,24 @@
apiVersion: v2
name: devops-chart
description: A Helm chart for Kubernetes
# A chart can be either an 'application' or a 'library' chart.
#
# Application charts are a collection of templates that can be packaged into versioned archives
# to be deployed.
#
# Library charts provide useful utilities or functions for the chart developer. They're included as
# a dependency of application charts to inject those utilities and functions into the rendering
# pipeline. Library charts do not define any templates and therefore cannot be deployed.
type: application
# This is the chart version. This version number should be incremented each time you make changes
# to the chart and its templates, including the app version.
# Versions are expected to follow Semantic Versioning (https://semver.org/)
version: 0.1.0
# This is the version number of the application being deployed. This version number should be
# incremented each time you make changes to the application. Versions are not expected to
# follow Semantic Versioning. They should reflect the version the application is using.
# It is recommended to use it with quotes.
appVersion: "1.16.0"

View File

@@ -0,0 +1,44 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: {{ .Values.app.name }}
labels:
app: {{ .Values.app.name }}
chart: {{ .Chart.Name }}
version: {{ .Chart.Version }}
spec:
replicas: {{ .Values.app.replicaCount }}
selector:
matchLabels:
app: {{ .Values.app.name }}
template:
metadata:
labels:
app: {{ .Values.app.name }}
{{- if .Values.monitoring.enabled }}
annotations:
prometheus.io/scrape: "{{ .Values.monitoring.prometheusScrape }}"
prometheus.io/port: "{{ .Values.app.service.targetPort }}"
prometheus.io/path: "/metrics"
{{- end }}
spec:
containers:
- name: {{ .Values.app.name }}
image: "{{ .Values.app.image.repository }}:{{ .Values.app.image.tag }}"
imagePullPolicy: {{ .Values.app.image.pullPolicy }}
ports:
- containerPort: {{ .Values.app.service.targetPort }}
name: http
env:
{{- range $key, $value := .Values.app.env }}
- name: {{ $key }}
value: {{ $value | quote }}
{{- end }}
resources:
{{- toYaml .Values.app.resources | nindent 10 }}
readinessProbe:
httpGet:
path: /health
port: {{ .Values.app.service.targetPort }}
initialDelaySeconds: 10
periodSeconds: 15

View File

@@ -0,0 +1,32 @@
# Configuration de l'application
app:
name: "devops-helm-app"
image:
repository: "devops-app"
tag: "local"
pullPolicy: "IfNotPresent"
replicaCount: 2
service:
type: NodePort
port: 80
targetPort: 8000
resources:
requests:
memory: "128Mi"
cpu: "100m"
limits:
memory: "256Mi"
cpu: "200m"
env:
ENV: "production"
LOG_LEVEL: "INFO"
# Monitoring
monitoring:
enabled: true
prometheusScrape: true