-- apiVersion: v1 kind: ConfigMap metadata: name: redis-clean-trigger namespace: k2 data: REDIS_TRIM: "10000" --- apiVersion: v1 kind: CronJob metadata: name: redis-clean-trigger spec: schedule: "0 6 * * *" successfulJobsHistoryLimit: 4 failedJobsHistoryLimit: 1 concurrencyPolicy: Forbid jobTemplate: spec: template: spec: #imagePullSecrets: # - name: k2-repository containers: - name: alarmlist-trigger image: 935062023832.dkr.ecr.eu-west-1.amazonaws.com/redis_clean_trigger:1.0.0 envFrom: - configMapRef: name: k2 - configMapRef: name: redis_clean_trigger env: - name: REDIS_PASSWORD valueFrom: secretKeyRef: name: redis key: redis-password resources: limits: memory: 128M requests: cpu: 100m memory: 128M restartPolicy: OnFailure