Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: enable backup sync for all campus #581

Merged
merged 1 commit into from
Feb 20, 2024

Conversation

42atomys
Copy link
Owner

Describe the pull request

This pull request enable the backup sync strategy for all activated campus (as a workaround of intra instability)

Checklist

  • I have made the modifications or added tests related to my PR
  • I have run the tests and linters locally and they pass
  • I have added/updated the documentation for my RP

@42atomys 42atomys merged commit 6e6bdba into main Feb 20, 2024
4 checks passed
@42atomys 42atomys deleted the chore/enable-backup-sync-for-all-campus branch February 20, 2024 01:09
@github-actions github-actions bot added the state/triage 🚦 Has not been triaged & therefore, not ready for work label Feb 20, 2024
Copy link

Terraform data for pre-cluster stack

Terraform Initialization ⚙️ success

Terraform Validation 🤖 success

Show Validation
Success! The configuration is valid.


Terraform Plan 📖 success

Show Plan
kubernetes_namespace.namespace["sandbox"]: Refreshing state... [id=sandbox]
kubernetes_namespace.namespace["production"]: Refreshing state... [id=production]
kubernetes_namespace.namespace["monitoring"]: Refreshing state... [id=monitoring]
kubernetes_namespace.namespace["previews"]: Refreshing state... [id=previews]
kubernetes_namespace.namespace["permission-manager"]: Refreshing state... [id=permission-manager]
kubernetes_namespace.namespace["staging"]: Refreshing state... [id=staging]
kubernetes_namespace.namespace["cert-manager"]: Refreshing state... [id=cert-manager]
kubernetes_namespace.namespace["istio-system"]: Refreshing state... [id=istio-system]
helm_release.istio_base: Refreshing state... [id=istio-base]
helm_release.sealed_secret: Refreshing state... [id=sealed-secret]
helm_release.rabbitmq_operator: Refreshing state... [id=primary]
helm_release.reflector: Refreshing state... [id=reflector]
helm_release.gateway: Refreshing state... [id=istio-ingressgateway]
helm_release.istiod: Refreshing state... [id=istiod]

No changes. Your infrastructure matches the configuration.

Terraform has compared your real infrastructure against your configuration
and found no differences, so no changes are needed.

Copy link

Terraform data for cluster stack

Terraform Initialization ⚙️ success

Terraform Validation 🤖 success

Show Validation
Success! The configuration is valid.


Terraform Plan 📖 success

Show Plan
module.prometheus.kubernetes_service.app[0]: Refreshing state... [id=monitoring/prometheus]
kubernetes_service_account.prometheus: Refreshing state... [id=monitoring/prometheus]
kubernetes_role.loki: Refreshing state... [id=monitoring/loki]
module.loki.kubernetes_service.app[0]: Refreshing state... [id=monitoring/loki]
module.tempo.kubernetes_service.app[0]: Refreshing state... [id=monitoring/tempo]
kubernetes_service_account.loki: Refreshing state... [id=monitoring/loki]
kubernetes_service_account.promtail: Refreshing state... [id=monitoring/promtail]
module.tempo.kubernetes_persistent_volume_claim.app["data"]: Refreshing state... [id=monitoring/tempo-data]
module.prometheus.kubernetes_persistent_volume_claim.app["data"]: Refreshing state... [id=monitoring/prometheus-data]
module.grafana.kubernetes_deployment.app[0]: Refreshing state... [id=monitoring/grafana]
module.promtail.kubernetes_service.app[0]: Refreshing state... [id=monitoring/promtail]
module.grafana.kubernetes_persistent_volume_claim.app["data"]: Refreshing state... [id=monitoring/grafana-data]
module.promtail.kubernetes_daemonset.app[0]: Refreshing state... [id=monitoring/promtail]
kubernetes_cluster_role.promtail: Refreshing state... [id=promtail]
module.tempo.kubernetes_config_map.app["config"]: Refreshing state... [id=monitoring/tempo-config]
module.grafana.kubernetes_service.app[0]: Refreshing state... [id=monitoring/grafana]
module.promtail.kubernetes_config_map.app["config"]: Refreshing state... [id=monitoring/promtail-config]
module.prometheus.kubernetes_config_map.app["config"]: Refreshing state... [id=monitoring/prometheus-config]
kubernetes_cluster_role.prometheus: Refreshing state... [id=prometheus]
module.loki.kubernetes_persistent_volume_claim.app["data"]: Refreshing state... [id=monitoring/loki-data]
module.loki.kubernetes_config_map.app["config"]: Refreshing state... [id=monitoring/loki-config]
kubernetes_service_account.tempo: Refreshing state... [id=monitoring/tempo]
module.cert_manager.null_resource.cert_manager_ovh_source: Refreshing state... [id=6901452211892208863]
module.cert_manager.helm_release.cert_manager: Refreshing state... [id=cert-manager]
module.istio.kubectl_manifest.gateways["dev-s42-previews"]: Refreshing state... [id=/apis/networking.istio.io/v1alpha3/namespaces/previews/gateways/dev-s42-previews]
module.monitoring_routing.kubectl_manifest.virtual_services["app-s42-dashboards"]: Refreshing state... [id=/apis/networking.istio.io/v1alpha3/namespaces/monitoring/virtualservices/app-s42-dashboards]
module.istio.kubectl_manifest.gateways["app-s42"]: Refreshing state... [id=/apis/networking.istio.io/v1alpha3/namespaces/production/gateways/app-s42]
module.istio.kubectl_manifest.gateways["app-s42-dashboards"]: Refreshing state... [id=/apis/networking.istio.io/v1alpha3/namespaces/monitoring/gateways/app-s42-dashboards]
module.istio.kubectl_manifest.gateways["app-s42-next"]: Refreshing state... [id=/apis/networking.istio.io/v1alpha3/namespaces/staging/gateways/app-s42-next]
module.prometheus.kubernetes_stateful_set.app[0]: Refreshing state... [id=monitoring/prometheus]
module.loki.kubernetes_stateful_set.app[0]: Refreshing state... [id=monitoring/loki]
module.tempo.kubernetes_stateful_set.app[0]: Refreshing state... [id=monitoring/tempo]
kubernetes_role_binding.loki: Refreshing state... [id=monitoring/loki]
kubernetes_cluster_role_binding.promtail: Refreshing state... [id=promtail]
kubernetes_cluster_role_binding.prometheus: Refreshing state... [id=prometheus]
module.cert_manager.kubectl_manifest.certificates["dev-s42-sandbox"]: Refreshing state... [id=/apis/cert-manager.io/v1/namespaces/istio-system/certificates/dev-s42-sandbox]
module.cert_manager.kubernetes_role.cert_manager_webhook_ovh_secret_reader: Refreshing state... [id=cert-manager/cert-manager-webhook-ovh:secret-reader]
module.cert_manager.kubectl_manifest.certificates["dev-s42-previews"]: Refreshing state... [id=/apis/cert-manager.io/v1/namespaces/istio-system/certificates/dev-s42-previews]
module.cert_manager.kubectl_manifest.certificates["app-s42"]: Refreshing state... [id=/apis/cert-manager.io/v1/namespaces/istio-system/certificates/app-s42]
module.cert_manager.kubectl_manifest.certificates["app-s42-dashboards"]: Refreshing state... [id=/apis/cert-manager.io/v1/namespaces/istio-system/certificates/app-s42-dashboards]
module.cert_manager.kubectl_manifest.certificates["app-s42-next"]: Refreshing state... [id=/apis/cert-manager.io/v1/namespaces/istio-system/certificates/app-s42-next]
module.cert_manager.kubernetes_role_binding.cert_manager_webhook_ovh_secret_reader: Refreshing state... [id=cert-manager/cert-manager-webhook-ovh:secret-reader]
module.secrets.kubernetes_manifest.sealed_secret["ovh-credentials"]: Refreshing state...
module.cert_manager.helm_release.cert_manager_ovh: Refreshing state... [id=cert-manager-webhook-ovh]
module.secrets.kubernetes_manifest.sealed_secret["ghcr-creds"]: Refreshing state...
module.cert_manager.kubectl_manifest.issuers["ovh-staging-issuer"]: Refreshing state... [id=/apis/cert-manager.io/v1/clusterissuers/ovh-staging-issuer]
module.cert_manager.kubectl_manifest.self_signed_issuers["selfsigned-issuer"]: Refreshing state... [id=/apis/cert-manager.io/v1/clusterissuers/selfsigned-issuer]
module.cert_manager.kubectl_manifest.issuers["ovh-issuer"]: Refreshing state... [id=/apis/cert-manager.io/v1/clusterissuers/ovh-issuer]

No changes. Your infrastructure matches the configuration.

Terraform has compared your real infrastructure against your configuration
and found no differences, so no changes are needed.

Warning: "default_secret_name" is no longer applicable for Kubernetes v1.24.0 and above

  with kubernetes_service_account.prometheus,
  on monitoring.tf line 73, in resource "kubernetes_service_account" "prometheus":
  73: resource "kubernetes_service_account" "prometheus" {

Starting from version 1.24.0 Kubernetes does not automatically generate a
token for service accounts, in this case, "default_secret_name" will be empty

(and 3 more similar warnings elsewhere)

Copy link

Terraform data for apps stack

Terraform Initialization ⚙️ success

Terraform Validation 🤖 success

Show Validation
Success! The configuration is valid.


Terraform Plan 📖 success

Show Plan
module.s42.module.postgres.kubernetes_persistent_volume_claim.app["data"]: Refreshing state... [id=production/postgres-data]
module.s42.module.meilisearch.kubernetes_persistent_volume_claim.app["data"]: Refreshing state... [id=production/meilisearch-data]
module.s42.module.interface.kubernetes_service.app[0]: Refreshing state... [id=production/interface]
module.s42.module.postgres.kubernetes_service.app[0]: Refreshing state... [id=production/postgres]
module.s42.kubernetes_config_map.stud42_config: Refreshing state... [id=production/stud42-config]
module.s42.module.auth_service.kubernetes_service.app[0]: Refreshing state... [id=production/auth-service]
module.s42.module.auth_service.kubernetes_deployment.app[0]: Refreshing state... [id=production/auth-service]
module.s42.module.interface.kubernetes_deployment.app[0]: Refreshing state... [id=production/interface]
module.s42.module.api.kubernetes_service.app[0]: Refreshing state... [id=production/api]
module.s42.module.postgres.kubernetes_config_map.app["config"]: Refreshing state... [id=production/postgres-config]
module.s42.module.webhooks_processor.kubernetes_deployment.app[0]: Refreshing state... [id=production/webhooks-processor]
module.s42.module.dragonfly.kubernetes_persistent_volume_claim.app["data"]: Refreshing state... [id=production/dragonfly-data]
module.s42.module.api.kubernetes_deployment.app[0]: Refreshing state... [id=production/api]
module.s42.module.dragonfly.kubernetes_service.app[0]: Refreshing state... [id=production/dragonfly]
module.s42.module.meilisearch.kubernetes_service.app[0]: Refreshing state... [id=production/meilisearch]
module.s42.module.crawler_campus.kubernetes_cron_job_v1.app[0]: Refreshing state... [id=production/crawler-campus]
module.s42.module.meilisearch_clean_tasks.kubernetes_cron_job_v1.app[0]: Refreshing state... [id=production/meilisearch-clean-tasks]
module.s42.module.crawler_locations["lausanne"].kubernetes_cron_job_v1.app[0]: Refreshing state... [id=production/crawler-locations-lausanne]
module.s42.module.crawler_locations["paris"].kubernetes_cron_job_v1.app[0]: Refreshing state... [id=production/crawler-locations-paris]
module.s42.module.crawler_locations["tokyo"].kubernetes_cron_job_v1.app[0]: Refreshing state... [id=production/crawler-locations-tokyo]
module.s42.module.crawler_locations["angouleme"].kubernetes_cron_job_v1.app[0]: Refreshing state... [id=production/crawler-locations-angouleme]
module.s42.module.crawler_locations["helsinki"].kubernetes_cron_job_v1.app[0]: Refreshing state... [id=production/crawler-locations-helsinki]
module.s42.module.crawler_locations["seoul"].kubernetes_cron_job_v1.app[0]: Refreshing state... [id=production/crawler-locations-seoul]
module.s42.module.crawler_locations["malaga"].kubernetes_cron_job_v1.app[0]: Refreshing state... [id=production/crawler-locations-malaga]
module.s42.module.crawler_locations["vienna"].kubernetes_cron_job_v1.app[0]: Refreshing state... [id=production/crawler-locations-vienna]
module.s42.random_password.postgres: Refreshing state... [id=none]
module.s42.module.crawler_locations["mulhouse"].kubernetes_cron_job_v1.app[0]: Refreshing state... [id=production/crawler-locations-mulhouse]
module.s42.random_password.dragonfly: Refreshing state... [id=none]
module.s42.random_password.next_auth_secret: Refreshing state... [id=none]
module.s42.random_password.meilisearch_token: Refreshing state... [id=none]
module.webhooked.module.webhooked.kubernetes_config_map.app["config"]: Refreshing state... [id=production/webhooked-config]
module.webhooked.module.webhooked.kubernetes_service.app[0]: Refreshing state... [id=production/webhooked]
module.s42.module.istio.kubectl_manifest.virtual_services["app-s42"]: Refreshing state... [id=/apis/networking.istio.io/v1alpha3/namespaces/production/virtualservices/app-s42]
module.s42.kubernetes_manifest.rabbitmq_binding_webhooks_dlq: Refreshing state...
module.s42.kubernetes_manifest.rabbitmq_queue_webhooks_processing: Refreshing state...
module.s42.kubernetes_manifest.rabbitmq_queue_webhooks_dlq: Refreshing state...
module.s42.kubernetes_manifest.rabbitmq_policy_webhooks_dlq: Refreshing state...
module.webhooked.module.secrets.kubernetes_manifest.sealed_secret["s42-webhooked-secrets"]: Refreshing state...
module.s42.kubernetes_manifest.rabbitmq: Refreshing state...
module.s42.module.postgres.kubernetes_stateful_set.app[0]: Refreshing state... [id=production/postgres]
module.s42.module.auth_service.kubernetes_horizontal_pod_autoscaler_v2.app[0]: Refreshing state... [id=production/auth-service]
module.s42.module.interface.kubernetes_horizontal_pod_autoscaler_v2.app[0]: Refreshing state... [id=production/interface]
module.s42.module.webhooks_processor.kubernetes_horizontal_pod_autoscaler_v2.app[0]: Refreshing state... [id=production/webhooks-processor]
module.s42.module.service-token.kubernetes_manifest.sealed_secret["discord-token"]: Refreshing state...
module.s42.module.api.kubernetes_horizontal_pod_autoscaler_v2.app[0]: Refreshing state... [id=production/api]
module.s42.module.meilisearch.kubernetes_stateful_set.app[0]: Refreshing state... [id=production/meilisearch]
module.s42.module.service-token.kubernetes_manifest.sealed_secret["s42-service-token"]: Refreshing state...
module.s42.module.service-token.kubernetes_manifest.sealed_secret["sentry-dsns"]: Refreshing state...
module.s42.module.service-token.kubernetes_manifest.sealed_secret["auth-service-certs-jwk"]: Refreshing state...
module.s42.module.dragonfly.kubernetes_stateful_set.app[0]: Refreshing state... [id=production/dragonfly]
module.s42.module.service-token.kubernetes_manifest.sealed_secret["ovh-s3-credentials"]: Refreshing state...
module.s42.kubernetes_secret.next_auth_secret: Refreshing state... [id=production/next-auth-secret]
module.s42.module.service-token.kubernetes_manifest.sealed_secret["github-token"]: Refreshing state...
module.s42.module.dragonfly.kubernetes_secret.app["credentials"]: Refreshing state... [id=production/dragonfly-credentials]
module.s42.module.postgres.kubernetes_secret.app["credentials"]: Refreshing state... [id=production/postgres-credentials]
module.s42.module.service-token.kubernetes_manifest.sealed_secret["oauth2-providers"]: Refreshing state...
module.s42.module.meilisearch.kubernetes_secret.app["token"]: Refreshing state... [id=production/meilisearch-token]
module.webhooked.module.webhooked.kubernetes_deployment.app[0]: Refreshing state... [id=production/webhooked]
module.webhooked.module.webhooked.kubernetes_horizontal_pod_autoscaler_v2.app[0]: Refreshing state... [id=production/webhooked]
module.s42.kubernetes_pod_disruption_budget_v1.rabbitmq: Refreshing state... [id=production/rabbitmq]
module.s42.kubernetes_manifest.rabbitmq_exchange_webhooks: Refreshing state...

Terraform used the selected providers to generate the following execution
plan. Resource actions are indicated with the following symbols:
  + create
  ~ update in-place

Terraform will perform the following actions:

  # module.s42.module.api.kubernetes_deployment.app[0] will be updated in-place
  ~ resource "kubernetes_deployment" "app" {
        id               = "production/api"
        # (1 unchanged attribute hidden)

      ~ metadata {
          ~ labels           = {
              ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
              ~ "version"                      = "v0.32" -> "latest"
                # (5 unchanged elements hidden)
            }
            name             = "api"
            # (5 unchanged attributes hidden)
        }

      ~ spec {
            # (5 unchanged attributes hidden)

          ~ template {
              ~ metadata {
                  ~ labels      = {
                      ~ "version"                      = "v0.32" -> "latest"
                        # (4 unchanged elements hidden)
                    }
                    # (2 unchanged attributes hidden)
                }

              ~ spec {
                    # (12 unchanged attributes hidden)

                  ~ container {
                      ~ image                      = "ghcr.io/42atomys/stud42:v0.32" -> "ghcr.io/42atomys/stud42:latest"
                        name                       = "api"
                        # (8 unchanged attributes hidden)

                        # (24 unchanged blocks hidden)
                    }

                    # (3 unchanged blocks hidden)
                }
            }

            # (2 unchanged blocks hidden)
        }
    }

  # module.s42.module.api.kubernetes_horizontal_pod_autoscaler_v2.app[0] will be updated in-place
  ~ resource "kubernetes_horizontal_pod_autoscaler_v2" "app" {
        id = "production/api"

      ~ metadata {
          ~ labels           = {
              ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
              ~ "version"                      = "v0.32" -> "latest"
                # (5 unchanged elements hidden)
            }
            name             = "api"
            # (5 unchanged attributes hidden)
        }

        # (1 unchanged block hidden)
    }

  # module.s42.module.api.kubernetes_service.app[0] will be updated in-place
  ~ resource "kubernetes_service" "app" {
        id                     = "production/api"
        # (2 unchanged attributes hidden)

      ~ metadata {
          ~ labels           = {
              ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
              ~ "version"                      = "v0.32" -> "latest"
                # (5 unchanged elements hidden)
            }
            name             = "api"
            # (5 unchanged attributes hidden)
        }

        # (1 unchanged block hidden)
    }

  # module.s42.module.auth_service.kubernetes_deployment.app[0] will be updated in-place
  ~ resource "kubernetes_deployment" "app" {
        id               = "production/auth-service"
        # (1 unchanged attribute hidden)

      ~ metadata {
          ~ labels           = {
              ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
              ~ "version"                      = "v0.32" -> "latest"
                # (5 unchanged elements hidden)
            }
            name             = "auth-service"
            # (5 unchanged attributes hidden)
        }

      ~ spec {
            # (5 unchanged attributes hidden)

          ~ template {
              ~ metadata {
                  ~ labels      = {
                      ~ "version"                      = "v0.32" -> "latest"
                        # (4 unchanged elements hidden)
                    }
                    # (2 unchanged attributes hidden)
                }

              ~ spec {
                    # (12 unchanged attributes hidden)

                  ~ container {
                      ~ image                      = "ghcr.io/42atomys/stud42:v0.32" -> "ghcr.io/42atomys/stud42:latest"
                        name                       = "auth-service"
                        # (8 unchanged attributes hidden)

                        # (8 unchanged blocks hidden)
                    }

                    # (4 unchanged blocks hidden)
                }
            }

            # (2 unchanged blocks hidden)
        }
    }

  # module.s42.module.auth_service.kubernetes_horizontal_pod_autoscaler_v2.app[0] will be updated in-place
  ~ resource "kubernetes_horizontal_pod_autoscaler_v2" "app" {
        id = "production/auth-service"

      ~ metadata {
          ~ labels           = {
              ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
              ~ "version"                      = "v0.32" -> "latest"
                # (5 unchanged elements hidden)
            }
            name             = "auth-service"
            # (5 unchanged attributes hidden)
        }

        # (1 unchanged block hidden)
    }

  # module.s42.module.auth_service.kubernetes_service.app[0] will be updated in-place
  ~ resource "kubernetes_service" "app" {
        id                     = "production/auth-service"
        # (2 unchanged attributes hidden)

      ~ metadata {
          ~ labels           = {
              ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
              ~ "version"                      = "v0.32" -> "latest"
                # (5 unchanged elements hidden)
            }
            name             = "auth-service"
            # (5 unchanged attributes hidden)
        }

        # (1 unchanged block hidden)
    }

  # module.s42.module.crawler_campus.kubernetes_cron_job_v1.app[0] will be updated in-place
  ~ resource "kubernetes_cron_job_v1" "app" {
        id = "production/crawler-campus"

      ~ metadata {
          ~ labels           = {
              ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
              ~ "version"                      = "v0.32" -> "latest"
                # (5 unchanged elements hidden)
            }
            name             = "crawler-campus"
            # (5 unchanged attributes hidden)
        }

      ~ spec {
            # (6 unchanged attributes hidden)

          ~ job_template {
              ~ metadata {
                  ~ labels      = {
                      ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
                      ~ "version"                      = "v0.32" -> "latest"
                        # (5 unchanged elements hidden)
                    }
                    # (2 unchanged attributes hidden)
                }

              ~ spec {
                    # (7 unchanged attributes hidden)

                  ~ template {
                      ~ metadata {
                          ~ labels      = {
                              ~ "version"                      = "v0.32" -> "latest"
                                # (5 unchanged elements hidden)
                            }
                            # (2 unchanged attributes hidden)
                        }

                      ~ spec {
                            # (12 unchanged attributes hidden)

                          ~ container {
                              ~ image                      = "ghcr.io/42atomys/stud42:v0.32" -> "ghcr.io/42atomys/stud42:latest"
                                name                       = "crawler-campus"
                                # (8 unchanged attributes hidden)

                                # (12 unchanged blocks hidden)
                            }

                            # (3 unchanged blocks hidden)
                        }
                    }
                }
            }
        }
    }

  # module.s42.module.crawler_locations["angouleme"].kubernetes_cron_job_v1.app[0] will be updated in-place
  ~ resource "kubernetes_cron_job_v1" "app" {
        id = "production/crawler-locations-angouleme"

      ~ metadata {
          ~ labels           = {
              ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
              ~ "version"                      = "v0.32" -> "latest"
                # (5 unchanged elements hidden)
            }
            name             = "crawler-locations-angouleme"
            # (5 unchanged attributes hidden)
        }

      ~ spec {
            # (6 unchanged attributes hidden)

          ~ job_template {
              ~ metadata {
                  ~ labels      = {
                      ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
                      ~ "version"                      = "v0.32" -> "latest"
                        # (5 unchanged elements hidden)
                    }
                    # (2 unchanged attributes hidden)
                }

              ~ spec {
                    # (7 unchanged attributes hidden)

                  ~ template {
                      ~ metadata {
                          ~ labels      = {
                              ~ "version"                      = "v0.32" -> "latest"
                                # (5 unchanged elements hidden)
                            }
                            # (2 unchanged attributes hidden)
                        }

                      ~ spec {
                            # (12 unchanged attributes hidden)

                          ~ container {
                              ~ image                      = "ghcr.io/42atomys/stud42:v0.32" -> "ghcr.io/42atomys/stud42:latest"
                                name                       = "crawler-locations-angouleme"
                                # (8 unchanged attributes hidden)

                                # (14 unchanged blocks hidden)
                            }

                            # (3 unchanged blocks hidden)
                        }
                    }
                }
            }
        }
    }

  # module.s42.module.crawler_locations["helsinki"].kubernetes_cron_job_v1.app[0] will be updated in-place
  ~ resource "kubernetes_cron_job_v1" "app" {
        id = "production/crawler-locations-helsinki"

      ~ metadata {
          ~ labels           = {
              ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
              ~ "version"                      = "v0.32" -> "latest"
                # (5 unchanged elements hidden)
            }
            name             = "crawler-locations-helsinki"
            # (5 unchanged attributes hidden)
        }

      ~ spec {
            # (6 unchanged attributes hidden)

          ~ job_template {
              ~ metadata {
                  ~ labels      = {
                      ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
                      ~ "version"                      = "v0.32" -> "latest"
                        # (5 unchanged elements hidden)
                    }
                    # (2 unchanged attributes hidden)
                }

              ~ spec {
                    # (7 unchanged attributes hidden)

                  ~ template {
                      ~ metadata {
                          ~ labels      = {
                              ~ "version"                      = "v0.32" -> "latest"
                                # (5 unchanged elements hidden)
                            }
                            # (2 unchanged attributes hidden)
                        }

                      ~ spec {
                            # (12 unchanged attributes hidden)

                          ~ container {
                              ~ image                      = "ghcr.io/42atomys/stud42:v0.32" -> "ghcr.io/42atomys/stud42:latest"
                                name                       = "crawler-locations-helsinki"
                                # (8 unchanged attributes hidden)

                                # (14 unchanged blocks hidden)
                            }

                            # (3 unchanged blocks hidden)
                        }
                    }
                }
            }
        }
    }

  # module.s42.module.crawler_locations["lausanne"].kubernetes_cron_job_v1.app[0] will be updated in-place
  ~ resource "kubernetes_cron_job_v1" "app" {
        id = "production/crawler-locations-lausanne"

      ~ metadata {
          ~ labels           = {
              ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
              ~ "version"                      = "v0.32" -> "latest"
                # (5 unchanged elements hidden)
            }
            name             = "crawler-locations-lausanne"
            # (5 unchanged attributes hidden)
        }

      ~ spec {
            # (6 unchanged attributes hidden)

          ~ job_template {
              ~ metadata {
                  ~ labels      = {
                      ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
                      ~ "version"                      = "v0.32" -> "latest"
                        # (5 unchanged elements hidden)
                    }
                    # (2 unchanged attributes hidden)
                }

              ~ spec {
                    # (7 unchanged attributes hidden)

                  ~ template {
                      ~ metadata {
                          ~ labels      = {
                              ~ "version"                      = "v0.32" -> "latest"
                                # (5 unchanged elements hidden)
                            }
                            # (2 unchanged attributes hidden)
                        }

                      ~ spec {
                            # (12 unchanged attributes hidden)

                          ~ container {
                              ~ image                      = "ghcr.io/42atomys/stud42:v0.32" -> "ghcr.io/42atomys/stud42:latest"
                                name                       = "crawler-locations-lausanne"
                                # (8 unchanged attributes hidden)

                                # (14 unchanged blocks hidden)
                            }

                            # (3 unchanged blocks hidden)
                        }
                    }
                }
            }
        }
    }

  # module.s42.module.crawler_locations["madrid"].kubernetes_cron_job_v1.app[0] will be created
  + resource "kubernetes_cron_job_v1" "app" {
      + id = (known after apply)

      + metadata {
          + generation       = (known after apply)
          + labels           = {
              + "app"                          = "crawler-locations"
              + "app.kubernetes.io/created-by" = "github-actions"
              + "app.kubernetes.io/managed-by" = "terraform"
              + "app.kubernetes.io/part-of"    = "crawler-locations"
              + "app.kubernetes.io/version"    = "latest"
              + "kubernetes.io/name"           = "crawler-locations-madrid"
              + "version"                      = "latest"
            }
          + name             = "crawler-locations-madrid"
          + namespace        = "production"
          + resource_version = (known after apply)
          + uid              = (known after apply)
        }

      + spec {
          + concurrency_policy            = "Forbid"
          + failed_jobs_history_limit     = 3
          + schedule                      = "3 * * * *"
          + starting_deadline_seconds     = 0
          + successful_jobs_history_limit = 1
          + suspend                       = false

          + job_template {
              + metadata {
                  + generation       = (known after apply)
                  + labels           = {
                      + "app"                          = "crawler-locations"
                      + "app.kubernetes.io/created-by" = "github-actions"
                      + "app.kubernetes.io/managed-by" = "terraform"
                      + "app.kubernetes.io/part-of"    = "crawler-locations"
                      + "app.kubernetes.io/version"    = "latest"
                      + "kubernetes.io/name"           = "crawler-locations-madrid"
                      + "version"                      = "latest"
                    }
                  + name             = (known after apply)
                  + resource_version = (known after apply)
                  + uid              = (known after apply)
                }

              + spec {
                  + active_deadline_seconds    = 600
                  + backoff_limit              = 0
                  + completion_mode            = "NonIndexed"
                  + completions                = 1
                  + parallelism                = 1
                  + ttl_seconds_after_finished = "300"

                  + selector {
                      + match_labels = (known after apply)

                      + match_expressions {
                          + key      = (known after apply)
                          + operator = (known after apply)
                          + values   = (known after apply)
                        }
                    }

                  + template {
                      + metadata {
                          + annotations      = {
                              + "prometheus.io/path"   = "/metrics"
                              + "prometheus.io/port"   = "8080"
                              + "prometheus.io/scrape" = "false"
                            }
                          + generation       = (known after apply)
                          + labels           = {
                              + "app"                          = "crawler-locations"
                              + "app.kubernetes.io/created-by" = "github-actions"
                              + "app.kubernetes.io/managed-by" = "terraform"
                              + "kubernetes.io/name"           = "crawler-locations-madrid"
                              + "sidecar.istio.io/inject"      = "false"
                              + "version"                      = "latest"
                            }
                          + name             = (known after apply)
                          + resource_version = (known after apply)
                          + uid              = (known after apply)
                        }

                      + spec {
                          + automount_service_account_token  = true
                          + dns_policy                       = "ClusterFirst"
                          + enable_service_links             = true
                          + host_ipc                         = false
                          + host_network                     = false
                          + host_pid                         = false
                          + hostname                         = (known after apply)
                          + node_name                        = (known after apply)
                          + node_selector                    = {
                              + "nodepool" = "small"
                            }
                          + restart_policy                   = "Never"
                          + scheduler_name                   = (known after apply)
                          + service_account_name             = (known after apply)
                          + share_process_namespace          = false
                          + termination_grace_period_seconds = 30

                          + container {
                              + args                       = [
                                  + "--config",
                                  + "/config/stud42.yaml",
                                  + "jobs",
                                  + "crawler",
                                  + "locations",
                                  + "-c",
                                  + "22",
                                ]
                              + command                    = [
                                  + "stud42cli",
                                ]
                              + image                      = "ghcr.io/42atomys/stud42:latest"
                              + image_pull_policy          = "IfNotPresent"
                              + name                       = "crawler-locations-madrid"
                              + stdin                      = false
                              + stdin_once                 = false
                              + termination_message_path   = "/dev/termination-log"
                              + termination_message_policy = (known after apply)
                              + tty                        = false

                              + env {
                                  + name = "DATABASE_PASSWORD"

                                  + value_from {

                                      + secret_key_ref {
                                          + key  = "POSTGRES_PASSWORD_ENCODED"
                                          + name = "postgres-credentials"
                                        }
                                    }
                                }
                              + env {
                                  + name = "FORTY_TWO_ID"

                                  + value_from {

                                      + secret_key_ref {
                                          + key  = "FORTY_TWO_ID"
                                          + name = "oauth2-providers"
                                        }
                                    }
                                }
                              + env {
                                  + name = "FORTY_TWO_SECRET"

                                  + value_from {

                                      + secret_key_ref {
                                          + key  = "FORTY_TWO_SECRET"
                                          + name = "oauth2-providers"
                                        }
                                    }
                                }
                              + env {
                                  + name = "SEARCHENGINE_MEILISEARCH_TOKEN"

                                  + value_from {

                                      + secret_key_ref {
                                          + key  = "MEILI_MASTER_KEY"
                                          + name = "meilisearch-token"
                                        }
                                    }
                                }
                              + env {
                                  + name = "SENTRY_DSN"

                                  + value_from {

                                      + secret_key_ref {
                                          + key  = "API_DSN"
                                          + name = "sentry-dsns"
                                        }
                                    }
                                }
                              + env {
                                  + name  = "DATABASE_HOST"
                                  + value = "postgres.production.svc.cluster.local"
                                }
                              + env {
                                  + name  = "DATABASE_NAME"
                                  + value = "s42"
                                }
                              + env {
                                  + name  = "DATABASE_URL"
                                  + value = "postgresql://postgres:$(DATABASE_PASSWORD)@$(DATABASE_HOST):5432/$(DATABASE_NAME)?sslmode=disable"
                                }
                              + env {
                                  + name  = "DEBUG"
                                  + value = "true"
                                }
                              + env {
                                  + name  = "GO_ENV"
                                  + value = "production"
                                }
                              + env {
                                  + name  = "SEARCHENGINE_MEILISEARCH_HOST"
                                  + value = "http://meilisearch.production.svc.cluster.local:7700"
                                }

                              + resources {
                                  + limits   = {
                                      + "memory" = "128Mi"
                                    }
                                  + requests = {
                                      + "cpu"    = "5m"
                                      + "memory" = "42Mi"
                                    }
                                }

                              + security_context {
                                  + allow_privilege_escalation = false
                                  + privileged                 = false
                                  + read_only_root_filesystem  = false
                                  + run_as_group               = "1000"
                                  + run_as_non_root            = true
                                  + run_as_user                = "1000"
                                }

                              + volume_mount {
                                  + mount_path        = "/config"
                                  + mount_propagation = "None"
                                  + name              = "configuration"
                                  + read_only         = true
                                }
                            }

                          + image_pull_secrets {
                              + name = "ghcr-creds"
                            }

                          + readiness_gate {
                              + condition_type = (known after apply)
                            }

                          + security_context {
                              + fs_group        = "1000"
                              + run_as_group    = "1000"
                              + run_as_non_root = true
                              + run_as_user     = "1000"
                            }

                          + volume {
                              + name = "configuration"

                              + config_map {
                                  + default_mode = "0644"
                                  + name         = "stud42-config"
                                }
                            }
                        }
                    }
                }
            }
        }
    }

  # module.s42.module.crawler_locations["malaga"].kubernetes_cron_job_v1.app[0] will be updated in-place
  ~ resource "kubernetes_cron_job_v1" "app" {
        id = "production/crawler-locations-malaga"

      ~ metadata {
          ~ labels           = {
              ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
              ~ "version"                      = "v0.32" -> "latest"
                # (5 unchanged elements hidden)
            }
            name             = "crawler-locations-malaga"
            # (5 unchanged attributes hidden)
        }

      ~ spec {
          ~ schedule                      = "3 * * * *" -> "4 * * * *"
            # (5 unchanged attributes hidden)

          ~ job_template {
              ~ metadata {
                  ~ labels      = {
                      ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
                      ~ "version"                      = "v0.32" -> "latest"
                        # (5 unchanged elements hidden)
                    }
                    # (2 unchanged attributes hidden)
                }

              ~ spec {
                    # (7 unchanged attributes hidden)

                  ~ template {
                      ~ metadata {
                          ~ labels      = {
                              ~ "version"                      = "v0.32" -> "latest"
                                # (5 unchanged elements hidden)
                            }
                            # (2 unchanged attributes hidden)
                        }

                      ~ spec {
                            # (12 unchanged attributes hidden)

                          ~ container {
                              ~ image                      = "ghcr.io/42atomys/stud42:v0.32" -> "ghcr.io/42atomys/stud42:latest"
                                name                       = "crawler-locations-malaga"
                                # (8 unchanged attributes hidden)

                                # (14 unchanged blocks hidden)
                            }

                            # (3 unchanged blocks hidden)
                        }
                    }
                }
            }
        }
    }

  # module.s42.module.crawler_locations["mulhouse"].kubernetes_cron_job_v1.app[0] will be updated in-place
  ~ resource "kubernetes_cron_job_v1" "app" {
        id = "production/crawler-locations-mulhouse"

      ~ metadata {
          ~ labels           = {
              ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
              ~ "version"                      = "v0.32" -> "latest"
                # (5 unchanged elements hidden)
            }
            name             = "crawler-locations-mulhouse"
            # (5 unchanged attributes hidden)
        }

      ~ spec {
          ~ schedule                      = "4 * * * *" -> "5 * * * *"
            # (5 unchanged attributes hidden)

          ~ job_template {
              ~ metadata {
                  ~ labels      = {
                      ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
                      ~ "version"                      = "v0.32" -> "latest"
                        # (5 unchanged elements hidden)
                    }
                    # (2 unchanged attributes hidden)
                }

              ~ spec {
                    # (7 unchanged attributes hidden)

                  ~ template {
                      ~ metadata {
                          ~ labels      = {
                              ~ "version"                      = "v0.32" -> "latest"
                                # (5 unchanged elements hidden)
                            }
                            # (2 unchanged attributes hidden)
                        }

                      ~ spec {
                            # (12 unchanged attributes hidden)

                          ~ container {
                              ~ image                      = "ghcr.io/42atomys/stud42:v0.32" -> "ghcr.io/42atomys/stud42:latest"
                                name                       = "crawler-locations-mulhouse"
                                # (8 unchanged attributes hidden)

                                # (14 unchanged blocks hidden)
                            }

                            # (3 unchanged blocks hidden)
                        }
                    }
                }
            }
        }
    }

  # module.s42.module.crawler_locations["paris"].kubernetes_cron_job_v1.app[0] will be updated in-place
  ~ resource "kubernetes_cron_job_v1" "app" {
        id = "production/crawler-locations-paris"

      ~ metadata {
          ~ labels           = {
              ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
              ~ "version"                      = "v0.32" -> "latest"
                # (5 unchanged elements hidden)
            }
            name             = "crawler-locations-paris"
            # (5 unchanged attributes hidden)
        }

      ~ spec {
          ~ schedule                      = "5 * * * *" -> "6 * * * *"
            # (5 unchanged attributes hidden)

          ~ job_template {
              ~ metadata {
                  ~ labels      = {
                      ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
                      ~ "version"                      = "v0.32" -> "latest"
                        # (5 unchanged elements hidden)
                    }
                    # (2 unchanged attributes hidden)
                }

              ~ spec {
                    # (7 unchanged attributes hidden)

                  ~ template {
                      ~ metadata {
                          ~ labels      = {
                              ~ "version"                      = "v0.32" -> "latest"
                                # (5 unchanged elements hidden)
                            }
                            # (2 unchanged attributes hidden)
                        }

                      ~ spec {
                            # (12 unchanged attributes hidden)

                          ~ container {
                              ~ image                      = "ghcr.io/42atomys/stud42:v0.32" -> "ghcr.io/42atomys/stud42:latest"
                                name                       = "crawler-locations-paris"
                                # (8 unchanged attributes hidden)

                                # (14 unchanged blocks hidden)
                            }

                            # (3 unchanged blocks hidden)
                        }
                    }
                }
            }
        }
    }

  # module.s42.module.crawler_locations["sao-paulo"].kubernetes_cron_job_v1.app[0] will be created
  + resource "kubernetes_cron_job_v1" "app" {
      + id = (known after apply)

      + metadata {
          + generation       = (known after apply)
          + labels           = {
              + "app"                          = "crawler-locations"
              + "app.kubernetes.io/created-by" = "github-actions"
              + "app.kubernetes.io/managed-by" = "terraform"
              + "app.kubernetes.io/part-of"    = "crawler-locations"
              + "app.kubernetes.io/version"    = "latest"
              + "kubernetes.io/name"           = "crawler-locations-sao-paulo"
              + "version"                      = "latest"
            }
          + name             = "crawler-locations-sao-paulo"
          + namespace        = "production"
          + resource_version = (known after apply)
          + uid              = (known after apply)
        }

      + spec {
          + concurrency_policy            = "Forbid"
          + failed_jobs_history_limit     = 3
          + schedule                      = "7 * * * *"
          + starting_deadline_seconds     = 0
          + successful_jobs_history_limit = 1
          + suspend                       = false

          + job_template {
              + metadata {
                  + generation       = (known after apply)
                  + labels           = {
                      + "app"                          = "crawler-locations"
                      + "app.kubernetes.io/created-by" = "github-actions"
                      + "app.kubernetes.io/managed-by" = "terraform"
                      + "app.kubernetes.io/part-of"    = "crawler-locations"
                      + "app.kubernetes.io/version"    = "latest"
                      + "kubernetes.io/name"           = "crawler-locations-sao-paulo"
                      + "version"                      = "latest"
                    }
                  + name             = (known after apply)
                  + resource_version = (known after apply)
                  + uid              = (known after apply)
                }

              + spec {
                  + active_deadline_seconds    = 600
                  + backoff_limit              = 0
                  + completion_mode            = "NonIndexed"
                  + completions                = 1
                  + parallelism                = 1
                  + ttl_seconds_after_finished = "300"

                  + selector {
                      + match_labels = (known after apply)

                      + match_expressions {
                          + key      = (known after apply)
                          + operator = (known after apply)
                          + values   = (known after apply)
                        }
                    }

                  + template {
                      + metadata {
                          + annotations      = {
                              + "prometheus.io/path"   = "/metrics"
                              + "prometheus.io/port"   = "8080"
                              + "prometheus.io/scrape" = "false"
                            }
                          + generation       = (known after apply)
                          + labels           = {
                              + "app"                          = "crawler-locations"
                              + "app.kubernetes.io/created-by" = "github-actions"
                              + "app.kubernetes.io/managed-by" = "terraform"
                              + "kubernetes.io/name"           = "crawler-locations-sao-paulo"
                              + "sidecar.istio.io/inject"      = "false"
                              + "version"                      = "latest"
                            }
                          + name             = (known after apply)
                          + resource_version = (known after apply)
                          + uid              = (known after apply)
                        }

                      + spec {
                          + automount_service_account_token  = true
                          + dns_policy                       = "ClusterFirst"
                          + enable_service_links             = true
                          + host_ipc                         = false
                          + host_network                     = false
                          + host_pid                         = false
                          + hostname                         = (known after apply)
                          + node_name                        = (known after apply)
                          + node_selector                    = {
                              + "nodepool" = "small"
                            }
                          + restart_policy                   = "Never"
                          + scheduler_name                   = (known after apply)
                          + service_account_name             = (known after apply)
                          + share_process_namespace          = false
                          + termination_grace_period_seconds = 30

                          + container {
                              + args                       = [
                                  + "--config",
                                  + "/config/stud42.yaml",
                                  + "jobs",
                                  + "crawler",
                                  + "locations",
                                  + "-c",
                                  + "20",
                                ]
                              + command                    = [
                                  + "stud42cli",
                                ]
                              + image                      = "ghcr.io/42atomys/stud42:latest"
                              + image_pull_policy          = "IfNotPresent"
                              + name                       = "crawler-locations-sao-paulo"
                              + stdin                      = false
                              + stdin_once                 = false
                              + termination_message_path   = "/dev/termination-log"
                              + termination_message_policy = (known after apply)
                              + tty                        = false

                              + env {
                                  + name = "DATABASE_PASSWORD"

                                  + value_from {

                                      + secret_key_ref {
                                          + key  = "POSTGRES_PASSWORD_ENCODED"
                                          + name = "postgres-credentials"
                                        }
                                    }
                                }
                              + env {
                                  + name = "FORTY_TWO_ID"

                                  + value_from {

                                      + secret_key_ref {
                                          + key  = "FORTY_TWO_ID"
                                          + name = "oauth2-providers"
                                        }
                                    }
                                }
                              + env {
                                  + name = "FORTY_TWO_SECRET"

                                  + value_from {

                                      + secret_key_ref {
                                          + key  = "FORTY_TWO_SECRET"
                                          + name = "oauth2-providers"
                                        }
                                    }
                                }
                              + env {
                                  + name = "SEARCHENGINE_MEILISEARCH_TOKEN"

                                  + value_from {

                                      + secret_key_ref {
                                          + key  = "MEILI_MASTER_KEY"
                                          + name = "meilisearch-token"
                                        }
                                    }
                                }
                              + env {
                                  + name = "SENTRY_DSN"

                                  + value_from {

                                      + secret_key_ref {
                                          + key  = "API_DSN"
                                          + name = "sentry-dsns"
                                        }
                                    }
                                }
                              + env {
                                  + name  = "DATABASE_HOST"
                                  + value = "postgres.production.svc.cluster.local"
                                }
                              + env {
                                  + name  = "DATABASE_NAME"
                                  + value = "s42"
                                }
                              + env {
                                  + name  = "DATABASE_URL"
                                  + value = "postgresql://postgres:$(DATABASE_PASSWORD)@$(DATABASE_HOST):5432/$(DATABASE_NAME)?sslmode=disable"
                                }
                              + env {
                                  + name  = "DEBUG"
                                  + value = "true"
                                }
                              + env {
                                  + name  = "GO_ENV"
                                  + value = "production"
                                }
                              + env {
                                  + name  = "SEARCHENGINE_MEILISEARCH_HOST"
                                  + value = "http://meilisearch.production.svc.cluster.local:7700"
                                }

                              + resources {
                                  + limits   = {
                                      + "memory" = "128Mi"
                                    }
                                  + requests = {
                                      + "cpu"    = "5m"
                                      + "memory" = "42Mi"
                                    }
                                }

                              + security_context {
                                  + allow_privilege_escalation = false
                                  + privileged                 = false
                                  + read_only_root_filesystem  = false
                                  + run_as_group               = "1000"
                                  + run_as_non_root            = true
                                  + run_as_user                = "1000"
                                }

                              + volume_mount {
                                  + mount_path        = "/config"
                                  + mount_propagation = "None"
                                  + name              = "configuration"
                                  + read_only         = true
                                }
                            }

                          + image_pull_secrets {
                              + name = "ghcr-creds"
                            }

                          + readiness_gate {
                              + condition_type = (known after apply)
                            }

                          + security_context {
                              + fs_group        = "1000"
                              + run_as_group    = "1000"
                              + run_as_non_root = true
                              + run_as_user     = "1000"
                            }

                          + volume {
                              + name = "configuration"

                              + config_map {
                                  + default_mode = "0644"
                                  + name         = "stud42-config"
                                }
                            }
                        }
                    }
                }
            }
        }
    }

  # module.s42.module.crawler_locations["seoul"].kubernetes_cron_job_v1.app[0] will be updated in-place
  ~ resource "kubernetes_cron_job_v1" "app" {
        id = "production/crawler-locations-seoul"

      ~ metadata {
          ~ labels           = {
              ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
              ~ "version"                      = "v0.32" -> "latest"
                # (5 unchanged elements hidden)
            }
            name             = "crawler-locations-seoul"
            # (5 unchanged attributes hidden)
        }

      ~ spec {
          ~ schedule                      = "6 * * * *" -> "8 * * * *"
            # (5 unchanged attributes hidden)

          ~ job_template {
              ~ metadata {
                  ~ labels      = {
                      ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
                      ~ "version"                      = "v0.32" -> "latest"
                        # (5 unchanged elements hidden)
                    }
                    # (2 unchanged attributes hidden)
                }

              ~ spec {
                    # (7 unchanged attributes hidden)

                  ~ template {
                      ~ metadata {
                          ~ labels      = {
                              ~ "version"                      = "v0.32" -> "latest"
                                # (5 unchanged elements hidden)
                            }
                            # (2 unchanged attributes hidden)
                        }

                      ~ spec {
                            # (12 unchanged attributes hidden)

                          ~ container {
                              ~ image                      = "ghcr.io/42atomys/stud42:v0.32" -> "ghcr.io/42atomys/stud42:latest"
                                name                       = "crawler-locations-seoul"
                                # (8 unchanged attributes hidden)

                                # (14 unchanged blocks hidden)
                            }

                            # (3 unchanged blocks hidden)
                        }
                    }
                }
            }
        }
    }

  # module.s42.module.crawler_locations["tokyo"].kubernetes_cron_job_v1.app[0] will be updated in-place
  ~ resource "kubernetes_cron_job_v1" "app" {
        id = "production/crawler-locations-tokyo"

      ~ metadata {
          ~ labels           = {
              ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
              ~ "version"                      = "v0.32" -> "latest"
                # (5 unchanged elements hidden)
            }
            name             = "crawler-locations-tokyo"
            # (5 unchanged attributes hidden)
        }

      ~ spec {
          ~ schedule                      = "7 * * * *" -> "9 * * * *"
            # (5 unchanged attributes hidden)

          ~ job_template {
              ~ metadata {
                  ~ labels      = {
                      ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
                      ~ "version"                      = "v0.32" -> "latest"
                        # (5 unchanged elements hidden)
                    }
                    # (2 unchanged attributes hidden)
                }

              ~ spec {
                    # (7 unchanged attributes hidden)

                  ~ template {
                      ~ metadata {
                          ~ labels      = {
                              ~ "version"                      = "v0.32" -> "latest"
                                # (5 unchanged elements hidden)
                            }
                            # (2 unchanged attributes hidden)
                        }

                      ~ spec {
                            # (12 unchanged attributes hidden)

                          ~ container {
                              ~ image                      = "ghcr.io/42atomys/stud42:v0.32" -> "ghcr.io/42atomys/stud42:latest"
                                name                       = "crawler-locations-tokyo"
                                # (8 unchanged attributes hidden)

                                # (14 unchanged blocks hidden)
                            }

                            # (3 unchanged blocks hidden)
                        }
                    }
                }
            }
        }
    }

  # module.s42.module.crawler_locations["urduliz"].kubernetes_cron_job_v1.app[0] will be created
  + resource "kubernetes_cron_job_v1" "app" {
      + id = (known after apply)

      + metadata {
          + generation       = (known after apply)
          + labels           = {
              + "app"                          = "crawler-locations"
              + "app.kubernetes.io/created-by" = "github-actions"
              + "app.kubernetes.io/managed-by" = "terraform"
              + "app.kubernetes.io/part-of"    = "crawler-locations"
              + "app.kubernetes.io/version"    = "latest"
              + "kubernetes.io/name"           = "crawler-locations-urduliz"
              + "version"                      = "latest"
            }
          + name             = "crawler-locations-urduliz"
          + namespace        = "production"
          + resource_version = (known after apply)
          + uid              = (known after apply)
        }

      + spec {
          + concurrency_policy            = "Forbid"
          + failed_jobs_history_limit     = 3
          + schedule                      = "10 * * * *"
          + starting_deadline_seconds     = 0
          + successful_jobs_history_limit = 1
          + suspend                       = false

          + job_template {
              + metadata {
                  + generation       = (known after apply)
                  + labels           = {
                      + "app"                          = "crawler-locations"
                      + "app.kubernetes.io/created-by" = "github-actions"
                      + "app.kubernetes.io/managed-by" = "terraform"
                      + "app.kubernetes.io/part-of"    = "crawler-locations"
                      + "app.kubernetes.io/version"    = "latest"
                      + "kubernetes.io/name"           = "crawler-locations-urduliz"
                      + "version"                      = "latest"
                    }
                  + name             = (known after apply)
                  + resource_version = (known after apply)
                  + uid              = (known after apply)
                }

              + spec {
                  + active_deadline_seconds    = 600
                  + backoff_limit              = 0
                  + completion_mode            = "NonIndexed"
                  + completions                = 1
                  + parallelism                = 1
                  + ttl_seconds_after_finished = "300"

                  + selector {
                      + match_labels = (known after apply)

                      + match_expressions {
                          + key      = (known after apply)
                          + operator = (known after apply)
                          + values   = (known after apply)
                        }
                    }

                  + template {
                      + metadata {
                          + annotations      = {
                              + "prometheus.io/path"   = "/metrics"
                              + "prometheus.io/port"   = "8080"
                              + "prometheus.io/scrape" = "false"
                            }
                          + generation       = (known after apply)
                          + labels           = {
                              + "app"                          = "crawler-locations"
                              + "app.kubernetes.io/created-by" = "github-actions"
                              + "app.kubernetes.io/managed-by" = "terraform"
                              + "kubernetes.io/name"           = "crawler-locations-urduliz"
                              + "sidecar.istio.io/inject"      = "false"
                              + "version"                      = "latest"
                            }
                          + name             = (known after apply)
                          + resource_version = (known after apply)
                          + uid              = (known after apply)
                        }

                      + spec {
                          + automount_service_account_token  = true
                          + dns_policy                       = "ClusterFirst"
                          + enable_service_links             = true
                          + host_ipc                         = false
                          + host_network                     = false
                          + host_pid                         = false
                          + hostname                         = (known after apply)
                          + node_name                        = (known after apply)
                          + node_selector                    = {
                              + "nodepool" = "small"
                            }
                          + restart_policy                   = "Never"
                          + scheduler_name                   = (known after apply)
                          + service_account_name             = (known after apply)
                          + share_process_namespace          = false
                          + termination_grace_period_seconds = 30

                          + container {
                              + args                       = [
                                  + "--config",
                                  + "/config/stud42.yaml",
                                  + "jobs",
                                  + "crawler",
                                  + "locations",
                                  + "-c",
                                  + "40",
                                ]
                              + command                    = [
                                  + "stud42cli",
                                ]
                              + image                      = "ghcr.io/42atomys/stud42:latest"
                              + image_pull_policy          = "IfNotPresent"
                              + name                       = "crawler-locations-urduliz"
                              + stdin                      = false
                              + stdin_once                 = false
                              + termination_message_path   = "/dev/termination-log"
                              + termination_message_policy = (known after apply)
                              + tty                        = false

                              + env {
                                  + name = "DATABASE_PASSWORD"

                                  + value_from {

                                      + secret_key_ref {
                                          + key  = "POSTGRES_PASSWORD_ENCODED"
                                          + name = "postgres-credentials"
                                        }
                                    }
                                }
                              + env {
                                  + name = "FORTY_TWO_ID"

                                  + value_from {

                                      + secret_key_ref {
                                          + key  = "FORTY_TWO_ID"
                                          + name = "oauth2-providers"
                                        }
                                    }
                                }
                              + env {
                                  + name = "FORTY_TWO_SECRET"

                                  + value_from {

                                      + secret_key_ref {
                                          + key  = "FORTY_TWO_SECRET"
                                          + name = "oauth2-providers"
                                        }
                                    }
                                }
                              + env {
                                  + name = "SEARCHENGINE_MEILISEARCH_TOKEN"

                                  + value_from {

                                      + secret_key_ref {
                                          + key  = "MEILI_MASTER_KEY"
                                          + name = "meilisearch-token"
                                        }
                                    }
                                }
                              + env {
                                  + name = "SENTRY_DSN"

                                  + value_from {

                                      + secret_key_ref {
                                          + key  = "API_DSN"
                                          + name = "sentry-dsns"
                                        }
                                    }
                                }
                              + env {
                                  + name  = "DATABASE_HOST"
                                  + value = "postgres.production.svc.cluster.local"
                                }
                              + env {
                                  + name  = "DATABASE_NAME"
                                  + value = "s42"
                                }
                              + env {
                                  + name  = "DATABASE_URL"
                                  + value = "postgresql://postgres:$(DATABASE_PASSWORD)@$(DATABASE_HOST):5432/$(DATABASE_NAME)?sslmode=disable"
                                }
                              + env {
                                  + name  = "DEBUG"
                                  + value = "true"
                                }
                              + env {
                                  + name  = "GO_ENV"
                                  + value = "production"
                                }
                              + env {
                                  + name  = "SEARCHENGINE_MEILISEARCH_HOST"
                                  + value = "http://meilisearch.production.svc.cluster.local:7700"
                                }

                              + resources {
                                  + limits   = {
                                      + "memory" = "128Mi"
                                    }
                                  + requests = {
                                      + "cpu"    = "5m"
                                      + "memory" = "42Mi"
                                    }
                                }

                              + security_context {
                                  + allow_privilege_escalation = false
                                  + privileged                 = false
                                  + read_only_root_filesystem  = false
                                  + run_as_group               = "1000"
                                  + run_as_non_root            = true
                                  + run_as_user                = "1000"
                                }

                              + volume_mount {
                                  + mount_path        = "/config"
                                  + mount_propagation = "None"
                                  + name              = "configuration"
                                  + read_only         = true
                                }
                            }

                          + image_pull_secrets {
                              + name = "ghcr-creds"
                            }

                          + readiness_gate {
                              + condition_type = (known after apply)
                            }

                          + security_context {
                              + fs_group        = "1000"
                              + run_as_group    = "1000"
                              + run_as_non_root = true
                              + run_as_user     = "1000"
                            }

                          + volume {
                              + name = "configuration"

                              + config_map {
                                  + default_mode = "0644"
                                  + name         = "stud42-config"
                                }
                            }
                        }
                    }
                }
            }
        }
    }

  # module.s42.module.crawler_locations["vienna"].kubernetes_cron_job_v1.app[0] will be updated in-place
  ~ resource "kubernetes_cron_job_v1" "app" {
        id = "production/crawler-locations-vienna"

      ~ metadata {
          ~ labels           = {
              ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
              ~ "version"                      = "v0.32" -> "latest"
                # (5 unchanged elements hidden)
            }
            name             = "crawler-locations-vienna"
            # (5 unchanged attributes hidden)
        }

      ~ spec {
          ~ schedule                      = "8 * * * *" -> "11 * * * *"
            # (5 unchanged attributes hidden)

          ~ job_template {
              ~ metadata {
                  ~ labels      = {
                      ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
                      ~ "version"                      = "v0.32" -> "latest"
                        # (5 unchanged elements hidden)
                    }
                    # (2 unchanged attributes hidden)
                }

              ~ spec {
                    # (7 unchanged attributes hidden)

                  ~ template {
                      ~ metadata {
                          ~ labels      = {
                              ~ "version"                      = "v0.32" -> "latest"
                                # (5 unchanged elements hidden)
                            }
                            # (2 unchanged attributes hidden)
                        }

                      ~ spec {
                            # (12 unchanged attributes hidden)

                          ~ container {
                              ~ image                      = "ghcr.io/42atomys/stud42:v0.32" -> "ghcr.io/42atomys/stud42:latest"
                                name                       = "crawler-locations-vienna"
                                # (8 unchanged attributes hidden)

                                # (14 unchanged blocks hidden)
                            }

                            # (3 unchanged blocks hidden)
                        }
                    }
                }
            }
        }
    }

  # module.s42.module.crawler_locations["wolfsburg"].kubernetes_cron_job_v1.app[0] will be created
  + resource "kubernetes_cron_job_v1" "app" {
      + id = (known after apply)

      + metadata {
          + generation       = (known after apply)
          + labels           = {
              + "app"                          = "crawler-locations"
              + "app.kubernetes.io/created-by" = "github-actions"
              + "app.kubernetes.io/managed-by" = "terraform"
              + "app.kubernetes.io/part-of"    = "crawler-locations"
              + "app.kubernetes.io/version"    = "latest"
              + "kubernetes.io/name"           = "crawler-locations-wolfsburg"
              + "version"                      = "latest"
            }
          + name             = "crawler-locations-wolfsburg"
          + namespace        = "production"
          + resource_version = (known after apply)
          + uid              = (known after apply)
        }

      + spec {
          + concurrency_policy            = "Forbid"
          + failed_jobs_history_limit     = 3
          + schedule                      = "12 * * * *"
          + starting_deadline_seconds     = 0
          + successful_jobs_history_limit = 1
          + suspend                       = false

          + job_template {
              + metadata {
                  + generation       = (known after apply)
                  + labels           = {
                      + "app"                          = "crawler-locations"
                      + "app.kubernetes.io/created-by" = "github-actions"
                      + "app.kubernetes.io/managed-by" = "terraform"
                      + "app.kubernetes.io/part-of"    = "crawler-locations"
                      + "app.kubernetes.io/version"    = "latest"
                      + "kubernetes.io/name"           = "crawler-locations-wolfsburg"
                      + "version"                      = "latest"
                    }
                  + name             = (known after apply)
                  + resource_version = (known after apply)
                  + uid              = (known after apply)
                }

              + spec {
                  + active_deadline_seconds    = 600
                  + backoff_limit              = 0
                  + completion_mode            = "NonIndexed"
                  + completions                = 1
                  + parallelism                = 1
                  + ttl_seconds_after_finished = "300"

                  + selector {
                      + match_labels = (known after apply)

                      + match_expressions {
                          + key      = (known after apply)
                          + operator = (known after apply)
                          + values   = (known after apply)
                        }
                    }

                  + template {
                      + metadata {
                          + annotations      = {
                              + "prometheus.io/path"   = "/metrics"
                              + "prometheus.io/port"   = "8080"
                              + "prometheus.io/scrape" = "false"
                            }
                          + generation       = (known after apply)
                          + labels           = {
                              + "app"                          = "crawler-locations"
                              + "app.kubernetes.io/created-by" = "github-actions"
                              + "app.kubernetes.io/managed-by" = "terraform"
                              + "kubernetes.io/name"           = "crawler-locations-wolfsburg"
                              + "sidecar.istio.io/inject"      = "false"
                              + "version"                      = "latest"
                            }
                          + name             = (known after apply)
                          + resource_version = (known after apply)
                          + uid              = (known after apply)
                        }

                      + spec {
                          + automount_service_account_token  = true
                          + dns_policy                       = "ClusterFirst"
                          + enable_service_links             = true
                          + host_ipc                         = false
                          + host_network                     = false
                          + host_pid                         = false
                          + hostname                         = (known after apply)
                          + node_name                        = (known after apply)
                          + node_selector                    = {
                              + "nodepool" = "small"
                            }
                          + restart_policy                   = "Never"
                          + scheduler_name                   = (known after apply)
                          + service_account_name             = (known after apply)
                          + share_process_namespace          = false
                          + termination_grace_period_seconds = 30

                          + container {
                              + args                       = [
                                  + "--config",
                                  + "/config/stud42.yaml",
                                  + "jobs",
                                  + "crawler",
                                  + "locations",
                                  + "-c",
                                  + "44",
                                ]
                              + command                    = [
                                  + "stud42cli",
                                ]
                              + image                      = "ghcr.io/42atomys/stud42:latest"
                              + image_pull_policy          = "IfNotPresent"
                              + name                       = "crawler-locations-wolfsburg"
                              + stdin                      = false
                              + stdin_once                 = false
                              + termination_message_path   = "/dev/termination-log"
                              + termination_message_policy = (known after apply)
                              + tty                        = false

                              + env {
                                  + name = "DATABASE_PASSWORD"

                                  + value_from {

                                      + secret_key_ref {
                                          + key  = "POSTGRES_PASSWORD_ENCODED"
                                          + name = "postgres-credentials"
                                        }
                                    }
                                }
                              + env {
                                  + name = "FORTY_TWO_ID"

                                  + value_from {

                                      + secret_key_ref {
                                          + key  = "FORTY_TWO_ID"
                                          + name = "oauth2-providers"
                                        }
                                    }
                                }
                              + env {
                                  + name = "FORTY_TWO_SECRET"

                                  + value_from {

                                      + secret_key_ref {
                                          + key  = "FORTY_TWO_SECRET"
                                          + name = "oauth2-providers"
                                        }
                                    }
                                }
                              + env {
                                  + name = "SEARCHENGINE_MEILISEARCH_TOKEN"

                                  + value_from {

                                      + secret_key_ref {
                                          + key  = "MEILI_MASTER_KEY"
                                          + name = "meilisearch-token"
                                        }
                                    }
                                }
                              + env {
                                  + name = "SENTRY_DSN"

                                  + value_from {

                                      + secret_key_ref {
                                          + key  = "API_DSN"
                                          + name = "sentry-dsns"
                                        }
                                    }
                                }
                              + env {
                                  + name  = "DATABASE_HOST"
                                  + value = "postgres.production.svc.cluster.local"
                                }
                              + env {
                                  + name  = "DATABASE_NAME"
                                  + value = "s42"
                                }
                              + env {
                                  + name  = "DATABASE_URL"
                                  + value = "postgresql://postgres:$(DATABASE_PASSWORD)@$(DATABASE_HOST):5432/$(DATABASE_NAME)?sslmode=disable"
                                }
                              + env {
                                  + name  = "DEBUG"
                                  + value = "true"
                                }
                              + env {
                                  + name  = "GO_ENV"
                                  + value = "production"
                                }
                              + env {
                                  + name  = "SEARCHENGINE_MEILISEARCH_HOST"
                                  + value = "http://meilisearch.production.svc.cluster.local:7700"
                                }

                              + resources {
                                  + limits   = {
                                      + "memory" = "128Mi"
                                    }
                                  + requests = {
                                      + "cpu"    = "5m"
                                      + "memory" = "42Mi"
                                    }
                                }

                              + security_context {
                                  + allow_privilege_escalation = false
                                  + privileged                 = false
                                  + read_only_root_filesystem  = false
                                  + run_as_group               = "1000"
                                  + run_as_non_root            = true
                                  + run_as_user                = "1000"
                                }

                              + volume_mount {
                                  + mount_path        = "/config"
                                  + mount_propagation = "None"
                                  + name              = "configuration"
                                  + read_only         = true
                                }
                            }

                          + image_pull_secrets {
                              + name = "ghcr-creds"
                            }

                          + readiness_gate {
                              + condition_type = (known after apply)
                            }

                          + security_context {
                              + fs_group        = "1000"
                              + run_as_group    = "1000"
                              + run_as_non_root = true
                              + run_as_user     = "1000"
                            }

                          + volume {
                              + name = "configuration"

                              + config_map {
                                  + default_mode = "0644"
                                  + name         = "stud42-config"
                                }
                            }
                        }
                    }
                }
            }
        }
    }

  # module.s42.module.interface.kubernetes_deployment.app[0] will be updated in-place
  ~ resource "kubernetes_deployment" "app" {
        id               = "production/interface"
        # (1 unchanged attribute hidden)

      ~ metadata {
          ~ labels           = {
              ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
              ~ "version"                      = "v0.32" -> "latest"
                # (5 unchanged elements hidden)
            }
            name             = "interface"
            # (5 unchanged attributes hidden)
        }

      ~ spec {
            # (5 unchanged attributes hidden)

          ~ template {
              ~ metadata {
                  ~ labels      = {
                      ~ "version"                      = "v0.32" -> "latest"
                        # (4 unchanged elements hidden)
                    }
                    # (2 unchanged attributes hidden)
                }

              ~ spec {
                    # (12 unchanged attributes hidden)

                  ~ container {
                      ~ image                      = "ghcr.io/42atomys/stud42:v0.32" -> "ghcr.io/42atomys/stud42:latest"
                        name                       = "interface"
                        # (8 unchanged attributes hidden)

                        # (32 unchanged blocks hidden)
                    }

                    # (3 unchanged blocks hidden)
                }
            }

            # (2 unchanged blocks hidden)
        }
    }

  # module.s42.module.interface.kubernetes_horizontal_pod_autoscaler_v2.app[0] will be updated in-place
  ~ resource "kubernetes_horizontal_pod_autoscaler_v2" "app" {
        id = "production/interface"

      ~ metadata {
          ~ labels           = {
              ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
              ~ "version"                      = "v0.32" -> "latest"
                # (5 unchanged elements hidden)
            }
            name             = "interface"
            # (5 unchanged attributes hidden)
        }

        # (1 unchanged block hidden)
    }

  # module.s42.module.interface.kubernetes_service.app[0] will be updated in-place
  ~ resource "kubernetes_service" "app" {
        id                     = "production/interface"
        # (2 unchanged attributes hidden)

      ~ metadata {
          ~ labels           = {
              ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
              ~ "version"                      = "v0.32" -> "latest"
                # (5 unchanged elements hidden)
            }
            name             = "interface"
            # (5 unchanged attributes hidden)
        }

        # (1 unchanged block hidden)
    }

  # module.s42.module.meilisearch_clean_tasks.kubernetes_cron_job_v1.app[0] will be updated in-place
  ~ resource "kubernetes_cron_job_v1" "app" {
        id = "production/meilisearch-clean-tasks"

      ~ spec {
            # (6 unchanged attributes hidden)

          ~ job_template {

              ~ spec {
                    # (7 unchanged attributes hidden)

                  ~ template {

                      ~ spec {
                            # (12 unchanged attributes hidden)

                          ~ container {
                                name                       = "meilisearch-clean-tasks"
                                # (9 unchanged attributes hidden)

                              ~ resources {
                                  ~ limits   = {
                                      + "memory" = "128Mi"
                                    }
                                  ~ requests = {
                                      + "cpu"    = "100m"
                                      + "memory" = "128Mi"
                                    }
                                }

                                # (2 unchanged blocks hidden)
                            }

                            # (2 unchanged blocks hidden)
                        }

                        # (1 unchanged block hidden)
                    }
                }

                # (1 unchanged block hidden)
            }
        }

        # (1 unchanged block hidden)
    }

  # module.s42.module.webhooks_processor.kubernetes_deployment.app[0] will be updated in-place
  ~ resource "kubernetes_deployment" "app" {
        id               = "production/webhooks-processor"
        # (1 unchanged attribute hidden)

      ~ metadata {
          ~ labels           = {
              ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
              ~ "version"                      = "v0.32" -> "latest"
                # (5 unchanged elements hidden)
            }
            name             = "webhooks-processor"
            # (5 unchanged attributes hidden)
        }

      ~ spec {
            # (5 unchanged attributes hidden)

          ~ template {
              ~ metadata {
                  ~ labels      = {
                      ~ "version"                      = "v0.32" -> "latest"
                        # (5 unchanged elements hidden)
                    }
                    # (2 unchanged attributes hidden)
                }

              ~ spec {
                    # (12 unchanged attributes hidden)

                  ~ container {
                      ~ image                      = "ghcr.io/42atomys/stud42:v0.32" -> "ghcr.io/42atomys/stud42:latest"
                        name                       = "webhooks-processor"
                        # (8 unchanged attributes hidden)

                        # (20 unchanged blocks hidden)
                    }

                    # (3 unchanged blocks hidden)
                }
            }

            # (2 unchanged blocks hidden)
        }
    }

  # module.s42.module.webhooks_processor.kubernetes_horizontal_pod_autoscaler_v2.app[0] will be updated in-place
  ~ resource "kubernetes_horizontal_pod_autoscaler_v2" "app" {
        id = "production/webhooks-processor"

      ~ metadata {
          ~ labels           = {
              ~ "app.kubernetes.io/version"    = "v0.32" -> "latest"
              ~ "version"                      = "v0.32" -> "latest"
                # (5 unchanged elements hidden)
            }
            name             = "webhooks-processor"
            # (5 unchanged attributes hidden)
        }

        # (1 unchanged block hidden)
    }

Plan: 4 to add, 22 to change, 0 to destroy.

─────────────────────────────────────────────────────────────────────────────

Saved the plan to: apps-tfplan

To perform exactly these actions, run the following command to apply:
    terraform apply "apps-tfplan"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
state/triage 🚦 Has not been triaged & therefore, not ready for work
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant