0

I have a job which is running redis pod.:

apiVersion: batch/v1
kind: Job
metadata:
  name: redis-job
spec:
  parallelism: 1
  ttlSecondsAfterFinished: 10
  template:
    metadata:
      name: redis-job
    spec:
      containers:
        - name: master
          image: redis
          command:
          - redis-server
          env:
            - name: MASTER
              value: "true"
          ports:
            - containerPort: 6379
      restartPolicy: Never

What I need in this setup is that when pod starts up it loads a list from file which is stored on GitLab.

The redis pod must stay alive until list is empty and I think I solved this with "ttl". I have another job which will consume this list.

1
  • Can you describe the actual problem that you're having? What exactly is failing or not working as you desire Apr 27 at 15:49

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.