apiVersion: batch/v1
kind: Job
metadata:
  generateName: floodrunner-sandboxrunner-
  namespace: floodrunner-sandboxrunner
spec:
  activeDeadlineSeconds: 180
  template:
    metadata:
      generateName: floodrunner-sandboxrunner-
      namespace: floodrunner-sandboxrunner
    spec:
      volumes:
        - name: dockervolume
          hostPath:
            path: '/var/run/docker.sock'
      containers:
        - name: floodrunner-sandboxrunner
          image: jellydock/floodrunner-sandboxrunner:v3.2.0
          securityContext:
            capabilities:
              add:
                - 'SYS_ADMIN'
          ports:
            - containerPort: 3000
          volumeMounts:
            - name: dockervolume
              mountPath: /var/run/docker.sock
          env:
            - name: FLOOD_TESTID
              value: __FLOOD_TESTID__
            - name: FLOOD_TEST_TYPE
              value: __FLOOD_TEST_TYPE__
            - name: FLOOD_MAX_RETRIES
              value: '__FLOOD_MAX_RETRIES__'
            - name: FLOOD_MAXALLOWEDSCREENSHOTS
              value: '__FLOOD_MAXALLOWEDSCREENSHOTS__'
            - name: AZURESTORAGE_ACCOUNTNAME
              value: __AZURESTORAGE_ACCOUNTNAME__
            - name: AZURESTORAGE_ACCESSKEY
              value: __AZURESTORAGE_ACCESSKEY__
            - name: AZURESTORAGE_CONTAINERFOLDERNAME
              value: __AZURESTORAGE_CONTAINERFOLDERNAME__
            - name: RABBITMQ_CONNECTIONSTRING
              value: __RABBITMQ_CONNECTIONSTRING__
            - name: RABBITMQ_QUEUENAME
              value: __RABBITMQ_QUEUENAME__
      restartPolicy: Never
