apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
namespace: easyai
resources:
  - namespace.yaml
  - service-account-rbac.yaml
  - application-config.yaml
  - application.yaml
  - database.yaml
  - network-policy.yaml
patches:
  - target:
      kind: Deployment
      name: easyai-api-hongkong
    patch: |-
      $patch: delete
      apiVersion: apps/v1
      kind: Deployment
      metadata:
        name: easyai-api-hongkong
  - target:
      kind: Deployment
      name: easyai-worker-hongkong
    patch: |-
      $patch: delete
      apiVersion: apps/v1
      kind: Deployment
      metadata:
        name: easyai-worker-hongkong
  - target:
      kind: Deployment
      name: easyai-web-hongkong
    patch: |-
      $patch: delete
      apiVersion: apps/v1
      kind: Deployment
      metadata:
        name: easyai-web-hongkong
  - target:
      kind: Service
      name: api-hongkong-edge
    patch: |-
      $patch: delete
      apiVersion: v1
      kind: Service
      metadata:
        name: api-hongkong-edge
  - target:
      kind: Service
      name: web-hongkong-edge
    patch: |-
      $patch: delete
      apiVersion: v1
      kind: Service
      metadata:
        name: web-hongkong-edge
images:
  # Deployment tooling must replace both sentinel digests with release-manifest
  # digests before server-side apply.
  - name: easyai-api
    newName: registry.cn-shanghai.aliyuncs.com/easyaigc/ai-gateway
    digest: sha256:0000000000000000000000000000000000000000000000000000000000000000
  - name: easyai-web
    newName: registry.cn-shanghai.aliyuncs.com/easyaigc/ai-gateway-web
    digest: sha256:0000000000000000000000000000000000000000000000000000000000000000
