first commit
This commit is contained in:
23
helm-chart/charts/backend/.helmignore
Normal file
23
helm-chart/charts/backend/.helmignore
Normal 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/
|
||||
24
helm-chart/charts/backend/Chart.yaml
Normal file
24
helm-chart/charts/backend/Chart.yaml
Normal file
@@ -0,0 +1,24 @@
|
||||
apiVersion: v2
|
||||
name: backend
|
||||
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.0.0"
|
||||
139
helm-chart/charts/backend/templates/configmap.yaml
Normal file
139
helm-chart/charts/backend/templates/configmap.yaml
Normal file
@@ -0,0 +1,139 @@
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
name: {{ include "chart.fullname" . }}-configmap
|
||||
labels:
|
||||
name: {{ include "chart.fullname" . }}-configmap
|
||||
data:
|
||||
application.yml: |
|
||||
spring:
|
||||
application:
|
||||
name: project-management
|
||||
profiles:
|
||||
active: local
|
||||
|
||||
service:
|
||||
token:
|
||||
enabled: true
|
||||
|
||||
# =============================
|
||||
# MySQL Database Configuration
|
||||
# =============================
|
||||
datasource:
|
||||
url: jdbc:mysql://e2e-84-26.ssdcloudindia.net:3306/project_management?useLocalSessionState=true&alwaysSendSetIsolation=false
|
||||
username: ikon_platform
|
||||
password: DOuCS7OX@un796b1QM
|
||||
driver-class-name: com.mysql.cj.jdbc.Driver
|
||||
hikari:
|
||||
connectionTimeout: 20000
|
||||
maximumPoolSize: 20
|
||||
|
||||
jpa:
|
||||
database-platform: org.hibernate.dialect.MySQL8Dialect
|
||||
hibernate:
|
||||
ddl-auto: update
|
||||
show-sql: true
|
||||
defer-datasource-initialization: false
|
||||
properties:
|
||||
hibernate:
|
||||
format_sql: true
|
||||
|
||||
|
||||
# =============================
|
||||
# Security Configuration
|
||||
# =============================
|
||||
security:
|
||||
oauth2:
|
||||
resourceserver:
|
||||
jwt:
|
||||
issuer-uri: https://holocron.keross.com/api/platform
|
||||
|
||||
|
||||
# =============================
|
||||
# IKON Platform Configurations
|
||||
# =============================
|
||||
ikon:
|
||||
connector:
|
||||
internal-auth:
|
||||
tokenUri: https://holocron.keross.com/api/platform/oauth2/token
|
||||
clientId: ikon-client-management
|
||||
clientSecret: F38Ysb4VEOSXUeISKcMyvpKqxtrIL8nf
|
||||
crypto:
|
||||
secretKey: MDEyMzQ1Njc4OWFiY2RlZjAxMjM0NTY3ODlhYmNkZWY=
|
||||
user:
|
||||
agent: "IKON App Server"
|
||||
platform:
|
||||
rest: https://holocron.keross.com/api
|
||||
logger:
|
||||
enabled: false
|
||||
|
||||
accessmanagement:
|
||||
init:
|
||||
file: ../../bpmn/project.json
|
||||
|
||||
|
||||
app:
|
||||
softwareId: "14ca0e46-bdb8-4436-a5bb-c6a664551478"
|
||||
softwareVerion: 1
|
||||
softwareName: "Project Management"
|
||||
softwareRepositoryName: ${spring.application.name}
|
||||
|
||||
|
||||
# =============================
|
||||
# Sales-CRM API Configuration
|
||||
# =============================
|
||||
salescrm:
|
||||
api:
|
||||
base-url: https://holocron.keross.com/api/salescrm/api/v1
|
||||
|
||||
|
||||
|
||||
# =============================
|
||||
# Logging Configuration
|
||||
# =============================
|
||||
logging:
|
||||
level:
|
||||
com.ikon: DEBUG
|
||||
file:
|
||||
name: "../logs/${spring.application.name}-app.log"
|
||||
|
||||
|
||||
# =============================
|
||||
# Server Configuration
|
||||
# =============================
|
||||
server:
|
||||
address: 0.0.0.0
|
||||
port: 8071
|
||||
|
||||
|
||||
# =============================
|
||||
# Eureka (Optional)
|
||||
# =============================
|
||||
eureka:
|
||||
instance:
|
||||
hostname: ${HOSTNAME}
|
||||
ipAddress: ${PROJECT_MANAGEMENT_BACKEND_SERVICE_SERVICE_HOST}
|
||||
preferIpAddress: true
|
||||
instance-id: ${spring.cloud.client.ip-address}:${spring.application.name}:${server.port}
|
||||
client:
|
||||
registerWithEureka: true
|
||||
fetchRegistry: true
|
||||
serviceUrl:
|
||||
defaultZone: http://ikon-discovery-service.ikon-platform.svc.cluster.local:8761/eureka
|
||||
|
||||
|
||||
management:
|
||||
endpoint:
|
||||
health:
|
||||
probes:
|
||||
enabled: true
|
||||
show-details: always
|
||||
endpoints:
|
||||
web:
|
||||
exposure:
|
||||
include: health
|
||||
health:
|
||||
livenessState:
|
||||
enabled: true
|
||||
readinessState:
|
||||
enabled: true
|
||||
62
helm-chart/charts/backend/templates/deployment.yaml
Normal file
62
helm-chart/charts/backend/templates/deployment.yaml
Normal file
@@ -0,0 +1,62 @@
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: {{ include "chart.fullname" . }}-deployment
|
||||
labels:
|
||||
{{- include "chart.labels" . | nindent 4 }}
|
||||
spec:
|
||||
replicas: {{ .Values.replicaCount }}
|
||||
selector:
|
||||
matchLabels:
|
||||
{{- include "chart.selectorLabels" . | nindent 6 }}
|
||||
template:
|
||||
metadata:
|
||||
{{- with .Values.podAnnotations }}
|
||||
annotations:
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
labels:
|
||||
{{- include "chart.selectorLabels" . | nindent 8 }}
|
||||
spec:
|
||||
{{- if .Values.global.imagePullSecret.enabled }}
|
||||
imagePullSecrets:
|
||||
- name: {{ .Release.Name }}-registry-secret
|
||||
{{- else if .Values.imagePullSecrets }}
|
||||
imagePullSecrets:
|
||||
{{- toYaml .Values.imagePullSecrets | nindent 8 }}
|
||||
{{- end }}
|
||||
containers:
|
||||
- name: {{ .Chart.Name }}
|
||||
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
|
||||
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||
ports:
|
||||
- name: http
|
||||
containerPort: {{ .Values.service.port }}
|
||||
protocol: TCP
|
||||
livenessProbe:
|
||||
httpGet:
|
||||
path: /actuator/health/liveness
|
||||
port: http
|
||||
initialDelaySeconds: {{ .Values.livenessProbe.initialDelaySeconds }}
|
||||
periodSeconds: {{ .Values.livenessProbe.periodSeconds }}
|
||||
readinessProbe:
|
||||
httpGet:
|
||||
path: /actuator/health/readiness
|
||||
port: http
|
||||
initialDelaySeconds: {{ .Values.readinessProbe.initialDelaySeconds }}
|
||||
periodSeconds: {{ .Values.readinessProbe.periodSeconds }}
|
||||
volumeMounts:
|
||||
- name: config-volume
|
||||
readOnly: true
|
||||
mountPath: /app/application.yml
|
||||
subPath: application.yml
|
||||
resources:
|
||||
{{- toYaml .Values.resources | nindent 10 }}
|
||||
env:
|
||||
{{- with .Values.env }}
|
||||
{{- toYaml . | nindent 10 }}
|
||||
{{- end }}
|
||||
volumes:
|
||||
- name: config-volume
|
||||
configMap:
|
||||
name: {{ include "chart.fullname" . }}-configmap
|
||||
49
helm-chart/charts/backend/templates/helpers.tpl
Normal file
49
helm-chart/charts/backend/templates/helpers.tpl
Normal file
@@ -0,0 +1,49 @@
|
||||
{{/*
|
||||
Expand the name of the chart.
|
||||
*/}}
|
||||
{{- define "chart.name" -}}
|
||||
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Create a default fully qualified app name.
|
||||
*/}}
|
||||
{{- define "chart.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 "chart.chart" -}}
|
||||
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Common labels
|
||||
*/}}
|
||||
{{- define "chart.labels" -}}
|
||||
helm.sh/chart: {{ include "chart.chart" . }}
|
||||
{{ include "chart.selectorLabels" . }}
|
||||
{{- if .Chart.AppVersion }}
|
||||
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
|
||||
{{- end }}
|
||||
app.kubernetes.io/managed-by: {{ .Release.Service }}
|
||||
{{- end }}
|
||||
|
||||
{{/*
|
||||
Selector labels
|
||||
*/}}
|
||||
{{- define "chart.selectorLabels" -}}
|
||||
app.kubernetes.io/name: {{ include "chart.name" . }}
|
||||
app.kubernetes.io/instance: {{ .Release.Name }}
|
||||
{{- end }}
|
||||
15
helm-chart/charts/backend/templates/service.yaml
Normal file
15
helm-chart/charts/backend/templates/service.yaml
Normal file
@@ -0,0 +1,15 @@
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: {{ include "chart.fullname" . }}-service
|
||||
labels:
|
||||
{{- include "chart.labels" . | nindent 4 }}
|
||||
spec:
|
||||
type: {{ .Values.service.type }}
|
||||
ports:
|
||||
- port: {{ .Values.service.port }}
|
||||
targetPort: http
|
||||
protocol: TCP
|
||||
name: http
|
||||
selector:
|
||||
{{- include "chart.selectorLabels" . | nindent 4 }}
|
||||
31
helm-chart/charts/backend/values.yaml
Normal file
31
helm-chart/charts/backend/values.yaml
Normal file
@@ -0,0 +1,31 @@
|
||||
# Default values for your helm chart
|
||||
replicaCount: 1
|
||||
|
||||
image:
|
||||
repository: ""
|
||||
tag: ""
|
||||
pullPolicy: IfNotPresent
|
||||
|
||||
podAnnotations: {}
|
||||
|
||||
service:
|
||||
type: ClusterIP
|
||||
port: 8060
|
||||
|
||||
resources:
|
||||
limits:
|
||||
cpu: 200m
|
||||
memory: 512Mi
|
||||
requests:
|
||||
cpu: 100m
|
||||
memory: 256Mi
|
||||
|
||||
livenessProbe:
|
||||
initialDelaySeconds: 40
|
||||
periodSeconds: 20
|
||||
|
||||
readinessProbe:
|
||||
initialDelaySeconds: 60
|
||||
periodSeconds: 10
|
||||
|
||||
env: []
|
||||
Reference in New Issue
Block a user