Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Error: release acs-export-cronjob failed: CronJob.batch "acs-export-cronjob" is invalid: [spec.jobTemplate.spec.template.spec.containers: Required value, spec.jobTemplate.spec.template.spec.restartPolicy: Unsupported value: "Always": supported values: "OnFailure", "Never"]
- NAME: acs-export-cronjob
- REVISION: 1
- RELEASED: Wed Oct 17 14:12:02 2018
- CHART: generic-job-0.1.0
- USER-SUPPLIED VALUES:
- applicationName: users
- command: publishAllForRealm
- image: <censored>.amazonaws.com/sonic/acs-export:latest
- jobAppArgs: ""
- jobVmArgs: ""
- jobgroup: acs-export-jobs
- name: acs-export-cronjob
- schedule: 0 * * * *
- COMPUTED VALUES:
- applicationName: users
- command: publishAllForRealm
- image: <censored>.amazonaws.com/sonic/acs-export:latest
- jobAppArgs: ""
- jobVmArgs: ""
- jobgroup: acs-export-jobs
- name: acs-export-cronjob
- resources:
- cpu: 100m
- memory: 1Gi
- schedule: 0 * * * *
- sonicNodeGroup: api
- springProfiles: export-job
- HOOKS:
- MANIFEST:
- ---
- # Source: generic-job/templates/rbac.yaml
- apiVersion: v1
- kind: ServiceAccount
- metadata:
- name: acs-export-cronjob-sa
- ---
- # Source: generic-job/templates/rbac.yaml
- kind: Role
- apiVersion: rbac.authorization.k8s.io/v1beta1
- metadata:
- name: acs-export-cronjob-manager
- rules:
- - apiGroups: ["extensions"]
- resources: ["deployments"]
- verbs: ["get"]
- ---
- # Source: generic-job/templates/rbac.yaml
- kind: RoleBinding
- apiVersion: rbac.authorization.k8s.io/v1beta1
- metadata:
- name: acs-export-cronjob-binding
- subjects:
- - kind: ServiceAccount
- name: acs-export-cronjob-sa
- roleRef:
- kind: Role
- name: acs-export-cronjob-manager
- apiGroup: rbac.authorization.k8s.io
- ---
- # Source: generic-job/templates/generic-job.yaml
- apiVersion: batch/v1beta1
- kind: CronJob
- metadata:
- name: acs-export-cronjob
- labels:
- app: generic-job
- chart: "generic-job-0.1.0"
- release: "acs-export-cronjob"
- heritage: "Tiller"
- spec:
- schedule: 0 * * * *
- successfulJobsHistoryLimit: 5
- failedJobsHistoryLimit: 5
- concurrencyPolicy: Forbid
- startingDeadlineSeconds: 120
- jobTemplate:
- spec:
- metadata:
- name: acs-export-cronjob
- labels:
- jobgroup: acs-export-jobs
- app: generic-job
- chart: "generic-job-0.1.0"
- release: "acs-export-cronjob"
- heritage: "Tiller"
- spec:
- template:
- metadata:
- labels:
- jobgroup: acs-export-jobs
- app: generic-job
- chart: "generic-job-0.1.0"
- release: "acs-export-cronjob"
- heritage: "Tiller"
- annotations:
- iam.amazonaws.com/role: arn:aws:iam::<censored>:role/k8s-service-role
- spec:
- restartPolicy: Never #<----------this is not 'Always'!!
- serviceAccountName: acs-export-cronjob-sa
- tolerations:
- - key: sonic-node-group
- operator: Equal
- value: api
- effect: NoSchedule
- nodeSelector:
- sonic-node-group: api
- volumes:
- - name: config
- emptyDir: {}
- initContainers:
- - name: "get-users-vmargs-from-deployment"
- image: <censored>.amazonaws.com/utils/kubectl-helm:latest
- command: ["sh", "-c", "kubectl -n eu1-test get deployment users-vertxapp -o jsonpath="{..spec.containers[0].env[?(@.name=='APP_SPECIFIC_VM_ARGS')].value}" > /config/users-vmargs && cat /config/users-vmargs"]
- volumeMounts:
- - mountPath: /config
- name: config
- - name: "get-users-yaml-appconfig-from-deployment"
- image: <censored>.amazonaws.com/utils/kubectl-helm:latest
- command: ["sh", "-c", "kubectl -n eu1-test get deployment users-vertxapp -o jsonpath="{..spec.containers[0].env[?(@.name=='APP_YAML_CONFIG')].value}" > /config/users-appconfig && cat /config/users-appconfig"]
- volumeMounts:
- - mountPath: /config
- name: config
- containers: #<--------this field is not missing!
- - image: <censored>.amazonaws.com/sonic/acs-export:latest
- imagePullPolicy: Always
- name: "users-batch"
- command:
- - "bash"
- - "-c"
- - 'APP_SPECIFIC_VM_ARGS="$(cat /config/users-vmargs) " APP_YAML_CONFIG="$(cat /config/users-appconfig)" /vertx-app/startvertx.sh'
- env:
- - name: FRENV
- value: "batch"
- - name: STACKNAME
- value: eu1-test
- - name: SPRING_PROFILES
- value: "export-job"
- - name: NAMESPACE
- valueFrom:
- fieldRef:
- fieldPath: metadata.namespace
- volumeMounts:
- - mountPath: /config
- name: config
- resources:
- limit:
- cpu: 100m
- memory: 1Gi
Add Comment
Please, Sign In to add comment