Skip to content

Conversation

@sandrotaje
Copy link
Collaborator

@sandrotaje sandrotaje commented Nov 25, 2025

Helm template output with additional image field because it rendered differently in the real one.

---
# Source: interop-eks-cronjob-chart/templates/serviceaccount.yaml
apiVersion: v1
kind: ServiceAccount
metadata:
  name: "interop-be-in-app-notification-cleaner"
  namespace: test-namespa
  labels:
    app.kubernetes.io/name: interop-be-in-app-notification-cleaner
    helm.sh/chart: interop-eks-cronjob-chart-1.10.2
    app: "interop-be-in-app-notification-cleaner"
    app.kubernetes.io/version: "develop"
    
    app.kubernetes.io/managed-by: Helm
  annotations:
    eks.amazonaws.com/role-arn: arn:aws:iam::505630707203:role/interop-be-in-app-notification-cleaner-dev-es1
---
# Source: interop-eks-cronjob-chart/templates/cronjob.yaml
apiVersion: batch/v1
kind: CronJob
metadata:
  name: "interop-be-in-app-notification-cleaner"
  namespace: test-namespa
  labels:
    app.kubernetes.io/name: interop-be-in-app-notification-cleaner
    helm.sh/chart: interop-eks-cronjob-chart-1.10.2
    app: "interop-be-in-app-notification-cleaner"
    app.kubernetes.io/version: "develop"
    
    app.kubernetes.io/managed-by: Helm
spec:
  schedule: "0 3 * * *"
  timeZone: 
  failedJobsHistoryLimit: 1 # K8s default is 1, Chart default is 1
  successfulJobsHistoryLimit: 1 # K8s default is 3, Chart default is 0
  suspend: false
  jobTemplate:
    metadata:
      labels:
        app.kubernetes.io/name: interop-be-in-app-notification-cleaner
        helm.sh/chart: interop-eks-cronjob-chart-1.10.2
        app: "interop-be-in-app-notification-cleaner"
        app.kubernetes.io/version: "develop"
        
        app.kubernetes.io/managed-by: Helm
      annotations:
    spec:
      backoffLimit: 6 # K8s default is 6, Chart default is 6
      activeDeadlineSeconds: 3600 # Chart default is 3600
      template:
        metadata:
          labels:
            app.kubernetes.io/name: interop-be-in-app-notification-cleaner
            helm.sh/chart: interop-eks-cronjob-chart-1.10.2
            app: "interop-be-in-app-notification-cleaner"
            app.kubernetes.io/version: "develop"
            
            app.kubernetes.io/managed-by: Helm
        spec:
          automountServiceAccountToken: true
          restartPolicy: OnFailure
          serviceAccountName: "interop-be-in-app-notification-cleaner"
          containers:
            - name: "interop-be-in-app-notification-cleaner"
              image: "505630707203.dkr.ecr.eu-south-1.amazonaws.com/interop-be-in-app-notification-cleaner:develop"
              imagePullPolicy: Always
              env:
                - name: "NAMESPACE"
                  valueFrom:
                    fieldRef:
                      fieldPath: "metadata.namespace"
                - name: "IN_APP_NOTIFICATION_DB_HOST"
                  valueFrom:
                    configMapKeyRef:
                      name: "common-in-app-notification-db"
                      key: "DB_HOST_RW"
                - name: "IN_APP_NOTIFICATION_DB_NAME"
                  valueFrom:
                    configMapKeyRef:
                      name: "common-in-app-notification-db"
                      key: "DB_NAME"
                - name: "IN_APP_NOTIFICATION_DB_PORT"
                  valueFrom:
                    configMapKeyRef:
                      name: "common-in-app-notification-db"
                      key: "DB_PORT"
                - name: "IN_APP_NOTIFICATION_DB_SCHEMA"
                  valueFrom:
                    configMapKeyRef:
                      name: "common-in-app-notification-db"
                      key: "DB_SCHEMA"
                - name: "IN_APP_NOTIFICATION_DB_USE_SSL"
                  valueFrom:
                    configMapKeyRef:
                      name: "common-in-app-notification-db"
                      key: "DB_USE_SSL"
                - name: "IN_APP_NOTIFICATION_DB_PASSWORD"
                  valueFrom:
                    secretKeyRef:
                      name: "in_app_notification_cleaner_user"
                      key: "password"
                - name: "IN_APP_NOTIFICATION_DB_USERNAME"
                  valueFrom:
                    secretKeyRef:
                      name: "in_app_notification_cleaner_user"
                      key: "username"
                - name: "DELETE_OLDER_THAN_DAYS"
                  value: "90"
              resources:
                limits:
                  cpu: null
                  memory: null
                requests:
                  cpu: null
                  memory: null

name: "interop-be-in-app-notification-cleaner"

serviceAccount:
roleArn: "arn:aws:iam::505630707203:role/interop-be-in-app-notification-cleaner-dev-es1" # TODO check role
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@micdes-pagopa is it correct the role here? I think you need to create a new one

IN_APP_NOTIFICATION_DB_USE_SSL: "common-in-app-notification-db.DB_USE_SSL"
envFromSecrets:
IN_APP_NOTIFICATION_DB_USERNAME: "in_app_notification_cleaner_user.username" # TODO check user
IN_APP_NOTIFICATION_DB_PASSWORD: "in_app_notification_cleaner_user.password" # TODO check user
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@micdes-pagopa What is the value here? Since it comes form secret I'm not sure I can view it. After knowing the name I'll update also the migration to grant the usage

@sandrotaje
Copy link
Collaborator Author

@micdes-pagopa is it right that in the resources all fields are nulls?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant