Skip to content

Commit 003b1c8

Browse files
committed
Merge branch 'main' into audit_logs_for_k8s_resource
2 parents a53f098 + 7715df5 commit 003b1c8

27 files changed

+2015
-0
lines changed
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
{"server":{"deployment":{"image_tag":"{{.Tag}}","image":"{{.Name}}"}},"pipelineName": "{{.PipelineName}}","releaseVersion":"{{.ReleaseVersion}}","deploymentType": "{{.DeploymentType}}", "app": "{{.App}}", "env": "{{.Env}}", "appMetrics": {{.AppMetrics}}}
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
apiVersion: v1
2+
appVersion: "1.0"
3+
description: A Helm chart for Kubernetes
4+
name: cronjob-chart_1-4-0
5+
version: 1.4.0
Lines changed: 173 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,173 @@
1+
# Mandatory configs
2+
kind: Job
3+
4+
jobConfigs:
5+
backoffLimit: 5
6+
activeDeadlineSeconds: 100
7+
parallelism: 1
8+
completions: 2
9+
suspend: false
10+
ttlSecondsAfterFinished: 100
11+
12+
cronjobConfigs:
13+
schedule: "* * * * *"
14+
startingDeadlineSeconds: 100
15+
concurrencyPolicy: Allow
16+
suspend: false
17+
successfulJobsHistoryLimit: 3
18+
failedJobsHistoryLimit: 1
19+
restartPolicy: OnFailure
20+
21+
kedaAutoscaling:
22+
envSourceContainerName: ""
23+
minReplicaCount: 1
24+
maxReplicaCount: 2
25+
pollingInterval: 30
26+
successfulJobsHistoryLimit: 5
27+
failedJobsHistoryLimit: 5
28+
rolloutStrategy: default
29+
scalingStrategy:
30+
strategy: "custom"
31+
customScalingQueueLengthDeduction: 1
32+
customScalingRunningJobPercentage: "0.5"
33+
pendingPodConditions:
34+
- "Ready"
35+
- "PodScheduled"
36+
- "AnyOtherCustomPodCondition"
37+
multipleScalersCalculation : "max"
38+
triggers:
39+
- type: rabbitmq
40+
metadata:
41+
queueName: hello
42+
host: RabbitMqHost
43+
queueLength : '5'
44+
authenticationRef: {}
45+
46+
MinReadySeconds: 60
47+
GracePeriod: 30
48+
image:
49+
pullPolicy: IfNotPresent
50+
service:
51+
type: ClusterIP
52+
enabled: false
53+
#name: "service-1234567890"
54+
annotations: {}
55+
# test1: test2
56+
# test3: test4
57+
ContainerPort:
58+
- name: app
59+
port: 8080
60+
servicePort: 80
61+
envoyPort: 8799
62+
useHTTP2: true
63+
supportStreaming: true
64+
idleTimeout: 1800s
65+
# servicemonitor:
66+
# enabled: true
67+
# path: /abc
68+
# scheme: 'http'
69+
# interval: 30s
70+
# scrapeTimeout: 20s
71+
# metricRelabelings:
72+
# - sourceLabels: [namespace]
73+
# regex: '(.*)'
74+
# replacement: myapp
75+
# targetLabel: target_namespace
76+
resources:
77+
# We usually recommend not to specify default resources and to leave this as a conscious
78+
# choice for the user. This also increases chances charts run on environments with little
79+
# resources, such as Minikube. If you do want to specify resources, uncomment the following
80+
# lines, adjust them as necessary, and remove the curly braces after 'resources:'.
81+
limits:
82+
cpu: 1
83+
memory: 200Mi
84+
requests:
85+
cpu: 0.10
86+
memory: 100Mi
87+
88+
# Optional configs
89+
90+
command:
91+
enabled: false
92+
value: []
93+
94+
args:
95+
enabled: false
96+
value:
97+
- /bin/sh
98+
- -c
99+
- touch /tmp/healthy; sleep 30; rm -rf /tmp/healthy; sleep 600
100+
101+
#For adding custom labels to pods
102+
103+
podLabels: {}
104+
# customKey: customValue
105+
podAnnotations: {}
106+
# customKey: customValue
107+
108+
rawYaml: []
109+
110+
initContainers: []
111+
## Additional init containers to run before the Scheduler pods.
112+
## for example, be used to run a sidecar that chown Logs storage.
113+
#- name: volume-mount-hack
114+
# image: busybox
115+
# command: ["sh", "-c", "chown -R 1000:1000 logs"]
116+
# volumeMounts:
117+
# - mountPath: /usr/local/airflow/logs
118+
# name: logs-data
119+
120+
containers: []
121+
## Additional containers to run along with application pods.
122+
## for example, be used to run a sidecar that chown Logs storage .
123+
#- name: volume-mount-hack
124+
# image: busybox
125+
# command: ["sh", "-c", "chown -R 1000:1000 logs"]
126+
# volumeMounts:
127+
# - mountPath: /usr/local/airflow/logs
128+
# name: logs-data
129+
130+
volumeMounts: []
131+
# - name: log-volume
132+
# mountPath: /var/log
133+
134+
volumes: []
135+
# - name: log-volume
136+
# emptyDir: {}
137+
138+
tolerations: []
139+
140+
Spec:
141+
Affinity:
142+
Key:
143+
# Key: kops.k8s.io/instancegroup
144+
Values:
145+
146+
prometheus:
147+
release: monitoring
148+
149+
server:
150+
deployment:
151+
image_tag: 1-95af053
152+
image: ""
153+
154+
servicemonitor:
155+
additionalLabels: {}
156+
157+
imagePullSecrets: []
158+
# - test1
159+
# - test2
160+
161+
containerSecurityContext:
162+
allowPrivilegeEscalation: false
163+
164+
podSecurityContext: {}
165+
# runAsUser: 1000
166+
# runAsGroup: 3000
167+
# fsGroup: 2000
168+
169+
shareProcessNamespace: false
170+
setHostnameAsFQDN: false
171+
readinessGates: []
172+
ephemeralContainers: []
173+
topologySpreadConstraints: []
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
MaxSurge: 1
2+
MaxUnavailable: 0
3+
GracePeriod: 30
4+
pauseForSecondsBeforeSwitchActive: 30
5+
waitForSecondsBeforeScalingDown: 30
6+
7+
Spec:
8+
Affinity:
9+
key: ""
10+
Values: nodes
11+
12+
secret:
13+
enabled: false
14+
data: {}
15+
# my_own_secret: S3ViZXJuZXRlcyBXb3Jrcw==
16+
17+
EnvVariables: []
18+
# - name: FLASK_ENV
19+
# value: qa
20+
21+
resources:
22+
# We usually recommend not to specify default resources and to leave this as a conscious
23+
# choice for the user. This also increases chances charts run on environments with little
24+
# resources, such as Minikube. If you do want to specify resources, uncomment the following
25+
# lines, adjust them as necessary, and remove the curly braces after 'resources:'.
26+
limits:
27+
cpu: "0.05"
28+
memory: 50Mi
29+
requests:
30+
cpu: "0.01"
31+
memory: 10Mi
32+
33+
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
deployment:
2+
strategy:
3+
blueGreen:
4+
autoPromotionSeconds: 30
5+
scaleDownDelaySeconds: 30
6+
previewReplicaCount: 1
7+
autoPromotionEnabled: false
8+
rolling:
9+
maxSurge: "25%"
10+
maxUnavailable: 1
11+
canary:
12+
maxSurge: "25%"
13+
maxUnavailable: 1
14+
steps:
15+
- setWeight: 25
16+
- pause:
17+
duration: 15 # 1 min
18+
- setWeight: 50
19+
- pause:
20+
duration: 15 # 1 min
21+
- setWeight: 75
22+
- pause:
23+
duration: 15 # 1 min
24+
recreate: {}
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
server:
2+
deployment:
3+
image_tag: IMAGE_TAG
4+
image: IMAGE_REPO
5+
enabled: false
6+
dbMigrationConfig:
7+
enabled: false
8+
9+
pauseForSecondsBeforeSwitchActive: 0
10+
waitForSecondsBeforeScalingDown: 0
11+
autoPromotionSeconds: 30
12+
13+
#used for deployment algo selection
14+
orchestrator.deploymant.algo: 1
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
{"ConfigSecrets":{"enabled":true,"secrets":[{"data":{"standard_key":"c3RhbmRhcmQtdmFsdWU="},"external":false,"externalType":"","mountPath":"/test","name":"normal-secret","type":"volume"},{"data":{"secret_key":"U0VDUkVUIERBVEE="},"external":true,"externalType":"AWSSecretsManager","mountPath":"","name":"external-secret-3","type":"environment"}]}}
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
1. Get the application URL by running these commands:
2+
{{- if contains "NodePort" .Values.service.type }}
3+
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include ".Chart.Name .fullname" . }})
4+
export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
5+
echo http://$NODE_IP:$NODE_PORT
6+
{{- else if contains "LoadBalancer" .Values.service.type }}
7+
NOTE: It may take a few minutes for the LoadBalancer IP to be available.
8+
You can watch the status of by running 'kubectl get svc -w {{ include ".Chart.Name .fullname" . }}'
9+
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include ".Chart.Name .fullname" . }} -o jsonpath='{.status.loadBalancer.ingress[0].ip}')
10+
echo http://$SERVICE_IP:{{ .Values.service.port }}
11+
{{- else if contains "ClusterIP" .Values.service.type }}
12+
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include ".Chart.Name .name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
13+
{{- end }}

0 commit comments

Comments
 (0)