EOX GitLab Instance

Commit 599d1815 authored by Nikola Jankovic's avatar Nikola Jankovic 💻
Browse files

updating helm for scheduler

made helm run with some defaults
parent bb9a8a84
Pipeline #17538 passed with stages
in 1 minute and 32 seconds
......@@ -23,8 +23,8 @@ deploy_latest:
- docker login -u "$CI_REGISTRY_USER" -p "$CI_REGISTRY_PASSWORD" "$CI_REGISTRY"
- docker build -t $CI_REGISTRY_IMAGE .
- docker push $CI_REGISTRY_IMAGE:latest
except:
- tags
only:
- master
deploy:
image: docker:20.10.8
......
apiVersion: v1
kind: ConfigMap
metadata:
name: {{ include "cache.fullname" . }}-scheduler-config
name: {{ include "vs-scheduler.fullname" . }}-config
data:
{{ (tpl (.Files.Glob "files/scheduler-config.yaml").AsConfig . ) | nindent 2}}
apiVersion: apps/v1
kind: Deployment
metadata:
name: {{ include "vs-cache.fullname" . }}-scheduler
name: {{ include "vs-scheduler.fullname" . }}
labels:
{{- include "vs-cache.labels" . | nindent 4 }}
{{- include "vs-scheduler.labels" . | nindent 4 }}
app.kubernetes.io/service: scheduler
spec:
replicas: {{ .Values.kubeConfig.scheduler.replicaCount }}
replicas: {{ .Values.replicaCount }}
selector:
matchLabels:
{{- include "vs-cache.selectorLabels" . | nindent 6 }}
{{- include "vs-scheduler.selectorLabels" . | nindent 6 }}
app.kubernetes.io/service: scheduler
strategy:
rollingUpdate:
......@@ -20,7 +20,7 @@ spec:
annotations:
prometheus.io/scrape: "false"
labels:
{{- include "vs-cache.selectorLabels" . | nindent 8 }}
{{- include "vs-scheduler.selectorLabels" . | nindent 8 }}
app.kubernetes.io/service: scheduler
spec:
{{- with .Values.imagePullSecrets }}
......@@ -28,19 +28,15 @@ spec:
{{- toYaml . | nindent 8 }}
{{- end }}
containers:
- name: {{ .Chart.Name }}-scheduler
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
- name: {{ .Chart.Name }}
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default ( print "release-" .Chart.AppVersion ) }}"
imagePullPolicy: {{ .Values.image.pullPolicy | default "IfNotPresent" }}
resources:
{{- toYaml .Values.resources | nindent 12 }}
args:
- /opt/scheduler/run-scheduler.sh
env:
{{- range $key, $value := .Values.envVar.general }}
- name: {{ $key }}
value: {{ $value | quote }}
{{- end }}
{{- range $key, $value := .Values.envVar.redis }}
{{- range $key, $value := .Values.global.env }}
- name: {{ $key }}
value: {{ $value | quote }}
{{- end }}
......@@ -62,7 +58,7 @@ spec:
items:
- key: scheduler-config.yaml
path: scheduler-config.yaml
name: {{ include "vs-cache.fullname" . }}-scheduler-config
name: {{ include "vs-scheduler.fullname" . }}-config
name: scheduler-config
{{- range $volumes := .Values.volumes }}
- {{- toYaml $volumes | nindent 12 }}
......
# Default values for scheduler.
# This is a YAML-formatted file.
# Declare variables to be passed into your templates.
replicaCount: 1
image:
repository: registry.gitlab.eox.at/vs/scheduler
pullPolicy: IfNotPresent
# Overrides the image tag whose default is the chart appVersion.
tag: ""
imagePullSecrets: []
nameOverride: ""
fullnameOverride: ""
serviceAccount:
# Specifies whether a service account should be created
create: true
# Annotations to add to the service account
annotations: {}
# The name of the service account to use.
# If not set and create is true, a name is generated using the fullname template
name: ""
podAnnotations: {}
config: {}
config:
schedules: []
resources:
{}
# We usually recommend not to specify default resources and to leave this as a conscious
# choice for the user. This also increases chances charts run on environments with little
# resources, such as Minikube. If you do want to specify resources, uncomment the following
# lines, adjust them as necessary, and remove the curly braces after 'resources:'.
# limits:
# cpu: 100m
# memory: 128Mi
# requests:
# cpu: 100m
# memory: 128Mi
resources: {}
autoscaling:
enabled: false
minReplicas: 1
maxReplicas: 100
targetCPUUtilizationPercentage: 80
# targetMemoryUtilizationPercentage: 80
nodeSelector: {}
affinity: {}
tolerations: []
volumes: []
volumeMounts: []
affinity: {}
global:
env:
REDIS_PORT: "6379"
......@@ -4,24 +4,24 @@ from setuptools import setup, find_packages
long_description = ""
setup(
name="scheduler",
name="scheduler",
version="2.0.0",
author="",
author_email="",
description="scheduler for PVS",
long_description=long_description,
long_description_content_type="text/markdown",
url="https://gitlab.eox.at/esa/prism/vs/-/tree/master/scheduler",
url="https://gitlab.eox.at/vs/scheduler",
packages=find_packages(),
classifiers=[
"Programming Language :: Python :: 3",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
],
python_requires='>=3.6',
python_requires=">=3.6",
entry_points={
"console_scripts": [
"scheduler = scheduler.cli:cli",
],
}
},
)
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