groups:
  - name: DDNS Updater Configuration
    description: Configure DDNS Updater
  - name: User and Group Configuration
    description: Configure User and Group for DDNS Updater
  - name: Network Configuration
    description: Configure Network for DDNS Updater
  - name: Storage Configuration
    description: Configure Storage for DDNS Updater
  - name: Resources Configuration
    description: Configure Resources for DDNS Updater

portals:
  web_portal:
    protocols:
      - "$kubernetes-resource_configmap_portal_protocol"
    host:
      - "$kubernetes-resource_configmap_portal_host"
    ports:
      - "$kubernetes-resource_configmap_portal_port"
    path: "$kubernetes-resource_configmap_portal_path"

questions:
  - variable: TZ
    group: DDNS Updater Configuration
    label: Timezone
    schema:
      type: string
      default: Etc/UTC
      required: true
      $ref:
        - definitions/timezone

  - variable: ddnsConfig
    label: ""
    group: DDNS Updater Configuration
    schema:
      type: dict
      attrs:
        - variable: config
          label: DNS Provider Configuration
          description: |
            Configuration for DDNS Updater.</br>
            Choose your provider in the following link for more information </br>
            https://github.com/qdm12/ddns-updater#configuration
          schema:
            type: list
            min: 1
            required: true
            empty: false
            default: []
            items:
              - variable: configEntry
                label: Configuration Entry
                schema:
                  type: dict
                  attrs:
                    - variable: provider
                      label: Provider
                      schema:
                        type: string
                        required: true
                        enum:
                          - value: aliyun
                            description: Aliyun
                          - value: allinkl
                            description: All-Inkl
                          - value: cloudflare
                            description: Cloudflare
                          - value: dd24
                            description: DD24
                          - value: ddnss
                            description: DDNSS
                          - value: desec
                            description: Desec
                          - value: digitalocean
                            description: Digital Ocean
                          - value: dnsomatic
                            description: DNS O Matic
                          - value: dnspod
                            description: DNS Pod
                          - value: dondominio
                            description: Don Dominio
                          - value: dreamhost
                            description: Dreamhost
                          - value: duckdns
                            description: Duck DNS
                          - value: dyn
                            description: DynDNS
                          - value: dynu
                            description: Dynu
                          - value: dynv6
                            description: DynV6
                          - value: easydns
                            description: EasyDNS
                          - value: freedns
                            description: FreeDNS
                          - value: gandi
                            description: Gandi
                          - value: gcp
                            description: GCP
                          - value: godaddy
                            description: GoDaddy
                          - value: goip
                            description: GoIP.de
                          - value: google
                            description: Google
                          - value: he
                            description: He.net
                          - value: hetzner
                            description: Hetzner
                          - value: infomaniak
                            description: Infomaniak
                          - value: inwx
                            description: INWX
                          - value: ionos
                            description: Ionos
                          - value: linode
                            description: Linode
                          - value: luadns
                            description: LuaDNS
                          - value: namecheap
                            description: Namecheap
                          - value: name.com
                            description: Name.com
                          - value: netcup
                            description: Netcup
                          - value: nowdns
                            description: NowDNS
                          - value: njalla
                            description: Njalla
                          - value: noip
                            description: NoIP
                          - value: opendns
                            description: OpenDNS
                          - value: ovh
                            description: OVH
                          - value: porkbun
                            description: Porkbun
                          - value: selfhost.de
                            description: Selfhost.de
                          - value: servercow
                            description: Servercow
                          - value: spdyn
                            description: Spdyn.de
                          - value: strato
                            description: Strato
                          - value: variomedia
                            description: Variomedia
                          - value: zoneedit
                            description: ZoneEdit
                    # Common to all providers
                    - variable: domain
                      label: Domain
                      description: |
                        Domain </br>
                        For example:</br>
                        - example.com</br>
                        - *.example.com</br>
                        - sub.example.com</br>
                      schema:
                        type: string
                        required: true
                        default: ""

                    - variable: host
                      label: Host (Deprecated)
                      description: |
                        DEPRECATED. Use Domain field instead.</br>
                        It will be removed in the near future.
                      schema:
                        type: string
                        default: ""
                    - variable: ipVersion
                      label: IP Version
                      description: |
                        IP Version. </br>
                        For example: IPv4
                      schema:
                        type: string
                        default: ""
                        enum:
                          - value: ipv4
                            description: IPv4
                          - value: ipv6
                            description: IPv6
                          - value: ""
                            description: IPv4 and IPv6

                    # Aliyun
                    - variable: aliyunAccessKey
                      label: Aliyun Access Key
                      description: Aliyun Access Key.
                      schema:
                        type: string
                        show_if: [["provider", "=", "aliyun"]]
                        required: true
                        private: true
                        empty: false
                    - variable: aliyunSecret
                      label: Aliyun Secret
                      description: Aliyun Secret.
                      schema:
                        type: string
                        show_if: [["provider", "=", "aliyun"]]
                        required: true
                        private: true
                        empty: false

                    # All-Inkl
                    - variable: allinklUsername
                      label: All-Inkl Username
                      description: All-Inkl Username.
                      schema:
                        type: string
                        show_if: [["provider", "=", "allinkl"]]
                        required: true
                        empty: false
                    - variable: allinklPassword
                      label: All-Inkl Password
                      description: All-Inkl Password.
                      schema:
                        type: string
                        show_if: [["provider", "=", "allinkl"]]
                        required: true
                        private: true
                        empty: false

                    # Cloudflare
                    - variable: cloudflareZoneID
                      label: Cloudflare Zone ID
                      description: |
                        Cloudflare Zone ID. </br>
                        You can find it in the Overview tab of your domain.
                      schema:
                        type: string
                        required: true
                        private: true
                        show_if: [["provider", "=", "cloudflare"]]
                    - variable: cloudflareTtl
                      label: Cloudflare TTL
                      description: |
                        Cloudflare TTL. </br>
                        1 = Automatic </br>
                        600 = 10 minutes
                      schema:
                        type: int
                        min: 1
                        required: true
                        show_if: [["provider", "=", "cloudflare"]]
                        default: 1
                    - variable: cloudflareProxied
                      label: Cloudflare Proxied
                      description: |
                        Cloudflare Proxied. </br>
                        True = Proxied </br>
                        False = DNS Only
                      schema:
                        type: boolean
                        show_if: [["provider", "=", "cloudflare"]]
                        default: false
                    - variable: cloudflareToken
                      label: Cloudflare Token
                      description: Cloudflare Token.
                      schema:
                        type: string
                        private: true
                        show_if: [["provider", "=", "cloudflare"]]
                    - variable: cloudflareUserServiceKey
                      label: Cloudflare User Service Key
                      description: Cloudflare User Service Key.
                      schema:
                        type: string
                        private: true
                        show_if: [["provider", "=", "cloudflare"]]
                    - variable: cloudflareEmail
                      label: Cloudflare Email
                      description: Cloudflare Email.
                      schema:
                        type: string
                        show_if: [["provider", "=", "cloudflare"]]
                    - variable: cloudflareApiKey
                      label: Cloudflare API Key
                      description: Cloudflare API Key.
                      schema:
                        type: string
                        show_if: [["provider", "=", "cloudflare"]]

                    # DD24
                    - variable: dd24Password
                      label: DD24 Password
                      description: DD24 Password.
                      schema:
                        type: string
                        show_if: [["provider", "=", "dd24"]]
                        required: true
                        private: true
                        empty: false

                    # DDNSS
                    - variable: ddnssUsername
                      label: DDNSS Username
                      description: DDNSS Username.
                      schema:
                        type: string
                        show_if: [["provider", "=", "ddnss"]]
                        required: true
                        empty: false
                    - variable: ddnssPassword
                      label: DDNSS Password
                      description: DDNSS Password.
                      schema:
                        type: string
                        show_if: [["provider", "=", "ddnss"]]
                        private: true
                        required: true
                        empty: false
                    - variable: ddnssDualStack
                      label: DDNSS Dual Stack
                      description: DDNSS Dual Stack.
                      schema:
                        type: boolean
                        show_if: [["provider", "=", "ddnss"]]
                        default: false

                    # Desec
                    - variable: desecToken
                      label: Desec Token
                      description: Desec Token.
                      schema:
                        type: string
                        show_if: [["provider", "=", "desec"]]
                        required: true
                        private: true
                        empty: false

                    # Digital Ocean
                    - variable: digitalOceanToken
                      label: Digital Ocean Token
                      description: Digital Ocean Token
                      schema:
                        type: string
                        show_if: [["provider", "=", "digitalocean"]]
                        required: true
                        private: true
                        empty: false

                    # DNS O Matic
                    - variable: dnsOMaticUsername
                      label: DNS O Matic Username
                      description: DNS O Matic Username.
                      schema:
                        type: string
                        show_if: [["provider", "=", "dnsomatic"]]
                        required: true
                        empty: false
                    - variable: dnsOMaticPassword
                      label: DNS O Matic Password
                      description: DNS O Matic Password.
                      schema:
                        type: string
                        show_if: [["provider", "=", "dnsomatic"]]
                        required: true
                        private: true
                        empty: false

                    # DNS Pod
                    - variable: dnsPodToken
                      label: DNS Pod Token
                      description: DNS Pod Token.
                      schema:
                        type: string
                        show_if: [["provider", "=", "dnspod"]]
                        required: true
                        private: true
                        empty: false

                    # Don Dominio
                    - variable: donDominioUsername
                      label: Don Dominio Username
                      description: Don Dominio Username.
                      schema:
                        type: string
                        show_if: [["provider", "=", "dondominio"]]
                        required: true
                        empty: false
                    - variable: donDominioPassword
                      label: Don Dominio Password
                      description: Don Dominio Password.
                      schema:
                        type: string
                        show_if: [["provider", "=", "dondominio"]]
                        required: true
                        private: true
                        empty: false
                    - variable: donDominioName
                      label: Don Dominio Name
                      description: Don Dominio Name.
                      schema:
                        type: string
                        show_if: [["provider", "=", "dondominio"]]
                        required: true
                        empty: false

                    # Dreamhost
                    - variable: dreamHostKey
                      label: Dreamhost Key
                      description: Dreamhost Key.
                      schema:
                        type: string
                        show_if: [["provider", "=", "dreamhost"]]
                        required: true
                        private: true
                        empty: false

                    # Duck DNS
                    - variable: duckdnsToken
                      label: Duck DNS Token
                      description: Duck DNS Token.
                      schema:
                        type: string
                        show_if: [["provider", "=", "duckdns"]]
                        required: true
                        private: true
                        empty: false

                    # DynDNS
                    - variable: dynClientKey
                      label: DynDNS Client Key
                      description: DynDNS Client Key.
                      schema:
                        type: string
                        show_if: [["provider", "=", "dyn"]]
                        required: true
                        private: true
                        empty: false
                    - variable: dynUsername
                      label: DynDNS Username
                      description: DynDNS Username.
                      schema:
                        type: string
                        show_if: [["provider", "=", "dyn"]]
                        required: true
                        empty: false

                    # Dynu
                    - variable: dynuUsername
                      label: Dynu Username
                      description: Dynu Username.
                      schema:
                        type: string
                        show_if: [["provider", "=", "dynu"]]
                        required: true
                        empty: false
                    - variable: dynuPassword
                      label: Dynu Password
                      description: Dynu Password.
                      schema:
                        type: string
                        show_if: [["provider", "=", "dynu"]]
                        required: true
                        private: true
                        empty: false
                    - variable: dynuGroup
                      label: Dynu Group
                      description: Dynu Group.
                      schema:
                        type: string
                        show_if: [["provider", "=", "dynu"]]

                    # DynV6
                    - variable: dynv6Token
                      label: DynV6 Token
                      description: DynV6 Token
                      schema:
                        type: string
                        show_if: [["provider", "=", "dynv6"]]
                        required: true
                        private: true
                        empty: false

                    # EasyDNS
                    - variable: easyDnsUsername
                      label: EasyDNS Username
                      description: EasyDNS Username.
                      schema:
                        type: string
                        show_if: [["provider", "=", "easydns"]]
                        required: true
                        empty: false
                    - variable: easyDnsToken
                      label: EasyDNS Token
                      description: EasyDNS Token.
                      schema:
                        type: string
                        show_if: [["provider", "=", "easydns"]]
                        required: true
                        private: true
                        empty: false

                    # FreeDNS
                    - variable: freeDnsToken
                      label: FreeDNS Token
                      description: FreeDNS Token.
                      schema:
                        type: string
                        show_if: [["provider", "=", "freedns"]]
                        required: true
                        empty: false

                    # Gandi
                    - variable: gandiKey
                      label: Gandi Key
                      description: Gandi Key.
                      schema:
                        type: string
                        show_if: [["provider", "=", "gandi"]]
                        required: true
                        private: true
                        empty: false
                    - variable: gandiTtl
                      label: Gandi TTL
                      description: Gandi TTL.
                      schema:
                        type: int
                        show_if: [["provider", "=", "gandi"]]
                        default: 3600
                        required: true

                    # GoIP.de
                    - variable: goipUsername
                      label: GoIP.de Username
                      description: GoIP.de Username.
                      schema:
                        type: string
                        show_if: [["provider", "=", "goip"]]
                        required: true
                        empty: false
                    - variable: goipPassword
                      label: GoIP.de Password
                      description: GoIP.de Password.
                      schema:
                        type: string
                        show_if: [["provider", "=", "goip"]]
                        required: true
                        private: true
                        empty: false

                    # GCP
                    - variable: gcpProject
                      label: GCP Project
                      description: GCP Project.
                      schema:
                        type: string
                        show_if: [["provider", "=", "gcp"]]
                        required: true
                        empty: false
                    - variable: gcpZone
                      label: GCP Zone
                      description: GCP Zone.
                      schema:
                        type: string
                        show_if: [["provider", "=", "gcp"]]
                        required: true
                        empty: false
                    - variable: gcpCredentials
                      label: GCP Credentials
                      description: |
                        GCP Credentials.</br>
                        Paste the JSON content in this field
                      schema:
                        type: string
                        max_length: 10000
                        show_if: [["provider", "=", "gcp"]]
                        required: true
                        private: true
                        empty: false

                    # GoDaddy
                    - variable: godaddyKey
                      label: GoDaddy Key
                      description: GoDaddy Key.
                      schema:
                        type: string
                        show_if: [["provider", "=", "godaddy"]]
                        required: true
                        private: true
                        empty: false
                    - variable: godaddySecret
                      label: GoDaddy Secret
                      description: GoDaddy Secret.
                      schema:
                        type: string
                        show_if: [["provider", "=", "godaddy"]]
                        required: true
                        private: true
                        empty: false

                    # Google
                    - variable: googleUsername
                      label: Google Username
                      description: Google Username.
                      schema:
                        type: string
                        show_if: [["provider", "=", "google"]]
                        required: true
                        empty: false
                    - variable: googlePassword
                      label: Google Password
                      description: Google Password.
                      schema:
                        type: string
                        show_if: [["provider", "=", "google"]]
                        required: true
                        private: true
                        empty: false

                    # He.net
                    - variable: hePassword
                      label: He.net Password
                      description: He.net Password.
                      schema:
                        type: string
                        show_if: [["provider", "=", "he"]]
                        required: true
                        private: true
                        empty: false

                    # Hetzner
                    - variable: hetznerToken
                      label: Hetzner Token
                      description: Hetzner Token.
                      schema:
                        type: string
                        show_if: [["provider", "=", "hetzner"]]
                        required: true
                        private: true
                        empty: false
                    - variable: hetznerZoneIdentifier
                      label: Hetzner Zone ID
                      description: Hetzner Zone ID.
                      schema:
                        type: string
                        show_if: [["provider", "=", "hetzner"]]
                        required: true
                        empty: false
                    - variable: hetznerTtl
                      label: Hetzner TTL
                      description: Hetzner TTL.
                      schema:
                        type: int
                        show_if: [["provider", "=", "hetzner"]]

                    # Infomaniak
                    - variable: infomaniakUsername
                      label: Infomaniak Username
                      description: Infomaniak Username.
                      schema:
                        type: string
                        show_if: [["provider", "=", "infomaniak"]]
                        required: true
                        empty: false
                    - variable: infomaniakPassword
                      label: Infomaniak Password
                      description: Infomaniak Password.
                      schema:
                        type: string
                        show_if: [["provider", "=", "infomaniak"]]
                        required: true
                        private: true
                        empty: false

                    # INWX
                    - variable: inwxUsername
                      label: INWX Username
                      description: INWX Username.
                      schema:
                        type: string
                        show_if: [["provider", "=", "inwx"]]
                        required: true
                        empty: false
                    - variable: inwxPassword
                      label: INWX Password
                      description: INWX Password.
                      schema:
                        type: string
                        show_if: [["provider", "=", "inwx"]]
                        private: true
                        required: true
                        empty: false

                    # Ionos
                    - variable: ionosApiKey
                      label: Ionos API Key
                      description: Ionos API Key.
                      schema:
                        type: string
                        show_if: [["provider", "=", "ionos"]]
                        required: true
                        private: true
                        empty: false

                    # Linode
                    - variable: linodeToken
                      label: Linode Token
                      description: Linode Token.
                      schema:
                        type: string
                        show_if: [["provider", "=", "linode"]]
                        required: true
                        private: true
                        empty: false

                    # LuaDNS
                    - variable: luadnsToken
                      label: LuaDNS Token
                      description: LuaDNS Token.
                      schema:
                        type: string
                        show_if: [["provider", "=", "luadns"]]
                        required: true
                        private: true
                        empty: false
                    - variable: luadnsEmail
                      label: LuaDNS Email
                      description: LuaDNS Email.
                      schema:
                        type: string
                        show_if: [["provider", "=", "luadns"]]
                        required: true
                        empty: false

                    # Namecheap
                    - variable: namecheapPassword
                      label: Namecheap Password
                      description: Namecheap Password.
                      schema:
                        type: string
                        show_if: [["provider", "=", "namecheap"]]
                        required: true
                        private: true
                        empty: false

                    # Name.com
                    - variable: namecomUsername
                      label: Name.com Username
                      description: Name.com Username.
                      schema:
                        type: string
                        show_if: [["provider", "=", "name.com"]]
                        required: true
                        empty: false
                    - variable: namecomToken
                      label: Name.com Token
                      description: Name.com Token.
                      schema:
                        type: string
                        show_if: [["provider", "=", "name.com"]]
                        required: true
                        private: true
                        empty: false
                    - variable: namecomTtl
                      label: Name.com TTL
                      description: Name.com TTL.
                      schema:
                        type: int
                        show_if: [["provider", "=", "name.com"]]
                        default: 300
                        required: true

                    # Netcup
                    - variable: netcupApiKey
                      label: Netcup API Key
                      description: Netcup API Key.
                      schema:
                        type: string
                        show_if: [["provider", "=", "netcup"]]
                        required: true
                        private: true
                        empty: false
                    - variable: netcupPassword
                      label: Netcup Password
                      description: Netcup Password.
                      schema:
                        type: string
                        show_if: [["provider", "=", "netcup"]]
                        required: true
                        private: true
                        empty: false
                    - variable: netcupCustomerNumber
                      label: Netcup Customer Number
                      description: Netcup Customer Number.
                      schema:
                        type: string
                        show_if: [["provider", "=", "netcup"]]
                        required: true
                        empty: false

                    # NowDNS
                    - variable: nowdnsUsername
                      label: NowDNS Username
                      description: NowDNS Username.
                      schema:
                        type: string
                        show_if: [["provider", "=", "nowdns"]]
                        required: true
                        empty: false
                    - variable: nowdnsPassword
                      label: NowDNS Password
                      description: NowDNS Password.
                      schema:
                        type: string
                        show_if: [["provider", "=", "nowdns"]]
                        required: true
                        private: true
                        empty: false

                    # Njalla
                    - variable: njallaKey
                      label: Njalla Key
                      description: Njalla Key.
                      schema:
                        type: string
                        show_if: [["provider", "=", "njalla"]]
                        required: true
                        private: true
                        empty: false

                    # NoIP
                    - variable: noipUsername
                      label: NoIP Username
                      description: NoIP Username.
                      schema:
                        type: string
                        show_if: [["provider", "=", "noip"]]
                        required: true
                        empty: false
                    - variable: noipPassword
                      label: NoIP Password
                      description: NoIP Password.
                      schema:
                        type: string
                        show_if: [["provider", "=", "noip"]]
                        required: true
                        private: true
                        empty: false

                    # OpenDNS
                    - variable: opendnsUsername
                      label: OpenDNS Username
                      description: OpenDNS Username.
                      schema:
                        type: string
                        show_if: [["provider", "=", "opendns"]]
                        required: true
                        empty: false
                    - variable: opendnsPassword
                      label: OpenDNS Password
                      description: OpenDNS Password.
                      schema:
                        type: string
                        show_if: [["provider", "=", "opendns"]]
                        required: true
                        private: true
                        empty: false

                    # OVH
                    - variable: ovhMode
                      label: OVH Mode
                      description: OVH Mode.
                      schema:
                        type: string
                        show_if: [["provider", "=", "ovh"]]
                        default: dynamic
                        required: true
                        enum:
                          - value: dynamic
                            description: Dynamic
                          - value: api
                            description: API
                    - variable: ovhUsername
                      label: OVH Username
                      description: OVH Username.
                      schema:
                        type: string
                        show_if: [["provider", "=", "ovh"]]
                    - variable: ovhPassword
                      label: OVH Password
                      description: OVH Password.
                      schema:
                        type: string
                        private: true
                        show_if: [["provider", "=", "ovh"]]
                    - variable: ovhApiEndpoint
                      label: OVH API Endpoint
                      description: OVH API Endpoint.
                      schema:
                        type: string
                        show_if: [["provider", "=", "ovh"]]
                        default: ovh-eu
                    - variable: ovhAppKey
                      label: OVH Application Key
                      description: OVH Application Key.
                      schema:
                        type: string
                        private: true
                        show_if: [["provider", "=", "ovh"]]
                    - variable: ovhAppSecret
                      label: OVH Application Secret
                      description: OVH Application Secret.
                      schema:
                        type: string
                        private: true
                        show_if: [["provider", "=", "ovh"]]
                    - variable: ovhConsumerKey
                      label: OVH Consumer Key
                      description: OVH Consumer Key.
                      schema:
                        type: string
                        private: true
                        show_if: [["provider", "=", "ovh"]]

                    # Porkbun
                    - variable: porkbunApiKey
                      label: Porkbun API Key
                      description: Porkbun API Key.
                      schema:
                        type: string
                        show_if: [["provider", "=", "porkbun"]]
                        required: true
                        private: true
                        empty: false
                    - variable: porkbunSecretApiKey
                      label: Porkbun Secret API Key
                      description: Porkbun Secret API Key.
                      schema:
                        type: string
                        show_if: [["provider", "=", "porkbun"]]
                        required: true
                        private: true
                        empty: false
                    - variable: porkbunTtl
                      label: Porkbun TTL
                      description: Porkbun TTL.
                      schema:
                        type: int
                        show_if: [["provider", "=", "porkbun"]]
                        default: 3600

                    # Selfhost.de
                    - variable: selfhostdeUsername
                      label: Selfhost.de Username
                      description: Selfhost.de Username.
                      schema:
                        type: string
                        show_if: [["provider", "=", "selfhost.de"]]
                        required: true
                        empty: false
                    - variable: selfhostdePassword
                      label: Selfhost.de Password
                      description: Selfhost.de Password.
                      schema:
                        type: string
                        show_if: [["provider", "=", "selfhost.de"]]
                        required: true
                        private: true
                        empty: false

                    # Servercow
                    - variable: servercowUsername
                      label: Servercow Username
                      description: Servercow Username.
                      schema:
                        type: string
                        show_if: [["provider", "=", "servercow"]]
                        required: true
                        empty: false
                    - variable: servercowPassword
                      label: Servercow Password
                      description: Servercow Password.
                      schema:
                        type: string
                        show_if: [["provider", "=", "servercow"]]
                        required: true
                        private: true
                        empty: false
                    - variable: servercowTtl
                      label: Servercow TTL
                      description: Servercow TTL.
                      schema:
                        type: int
                        show_if: [["provider", "=", "servercow"]]
                        default: 120

                    # Spdyn.de
                    - variable: spdynToken
                      label: Spdyn.de Token
                      description: Spdyn.de Token.
                      schema:
                        type: string
                        show_if: [["provider", "=", "spdyn"]]
                        required: true
                        private: true
                        empty: false
                    - variable: spdynUsername
                      label: Spdyn.de Username
                      description: Spdyn.de Username.
                      schema:
                        type: string
                        show_if: [["provider", "=", "spdyn"]]
                        required: true
                        empty: false
                    - variable: spdynPassword
                      label: Spdyn.de Password
                      description: Spdyn.de Password.
                      schema:
                        type: string
                        show_if: [["provider", "=", "spdyn"]]
                        required: true
                        private: true
                        empty: false

                    # Strato
                    - variable: stratoPassword
                      label: Strato Password
                      description: Strato Password.
                      schema:
                        type: string
                        show_if: [["provider", "=", "strato"]]
                        required: true
                        private: true
                        empty: false

                    # Variomedia
                    - variable: variomediaPassword
                      label: Variomedia Password
                      description: Variomedia Password.
                      schema:
                        type: string
                        show_if: [["provider", "=", "variomedia"]]
                        required: true
                        private: true
                        empty: false
                    - variable: variomediaEmail
                      label: Variomedia Email
                      description: Variomedia Email.
                      schema:
                        type: string
                        show_if: [["provider", "=", "variomedia"]]
                        required: true
                        empty: false

                    # ZoneEdit
                    - variable: zoneeditUsername
                      label: ZoneEdit Username
                      description: ZoneEdit Username.
                      schema:
                        type: string
                        show_if: [["provider", "=", "zoneedit"]]
                        required: true
                        empty: false
                    - variable: zoneeditToken
                      label: ZoneEdit Token
                      description: ZoneEdit Token.
                      schema:
                        type: string
                        show_if: [["provider", "=", "zoneedit"]]
                        required: true
                        private: true
                        empty: false

        - variable: period
          label: Update Period
          description: |
            Default period of IP address check, following this format:</br>
            5m = 5 minutes</br>
            1h = 1 hour</br>
            1h30m = 1 hour 30 minutes
          schema:
            type: string
            default: 5m
            required: true
        - variable: updateCooldownPeriod
          label: Update Cooldown Period
          description: |
            Duration to cooldown between updates for each record.
            This is useful to avoid being rate limited or banned,
            following this format:</br>
            5m = 5 minutes</br>
            1h = 1 hour</br>
            1h30m = 1 hour 30 minutes
          schema:
            type: string
            default: 5m
            required: true
        - variable: backupPeriod
          label: Backup Period
          description: |
            Set to a period to enable zip backups of data/config.json and
            data/updates.json in a zip file following this format:</br>
            0 = disabled</br>
            10h = 10 hours</br>
            20h30m = 20 hours 30 minutes
          schema:
            type: string
            default: 24h
            required: true
        - variable: httpTimeout
          label: HTTP Timeout
          description: |
            Default timeout for HTTP requests, following this format:</br>
            10s = 10 seconds</br>
            1m = 1 minute</br>
            1m30s = 1 minute 30 seconds
          schema:
            type: string
            default: 10s
            required: true
        - variable: publicIpDnsTimeout
          label: Public IP DNS Timeout
          description: |
            Public IP DNS query timeout, following this format:</br>
            3s = 3 seconds</br>
            1m = 1 minute</br>
            1m30s = 1 minute 30 seconds
          schema:
            type: string
            default: 3s
            required: true
        - variable: shoutrrrAddresses
          label: Shoutrrr Addresses
          description: |
            List of Shoutrrr addresses to send notifications to. </br>
            See https://containrrr.dev/shoutrrr/0.7/services/overview/ for more information.
          schema:
            type: list
            default: []
            items:
              - variable: address
                label: Address
                schema:
                  type: string
                  required: true
                  empty: false
        - variable: publicIpDnsProviders
          label: Public IP DNS Providers
          description: Providers to obtain the public IP address (IPv4 and/or IPv6)
          schema:
            type: list
            min: 1
            required: true
            empty: false
            default: [{ "provider": "all", "placeholder": "placeholder" }]
            items:
              - variable: publicIpDnsProviderEntry
                label: Public IP DNS Provider Entry
                schema:
                  type: dict
                  attrs:
                    - variable: provider
                      label: Provider
                      schema:
                        type: string
                        required: true
                        enum:
                          - value: all
                            description: All providers
                          - value: opendns
                            description: opendns
                          - value: cloudflare
                            description: Cloudflare
                    # Workaround for a UI bug that is fixed in the next release
                    # (Single items in a dict inside a list was getting converted to a list of strings)
                    - variable: placeholder
                      label: placeholder
                      schema:
                        type: string
                        default: placeholder
                        required: true
                        hidden: true
        - variable: publicIpHttpProviders
          label: Public IP HTTP Providers
          description: Providers to obtain the public IP address (IPv4 and/or IPv6)
          schema:
            type: list
            min: 1
            required: true
            empty: false
            default: [{ "provider": "all", "custom": "" }]
            items:
              - variable: publicIpHttpProviderEntry
                label: Public IP HTTP Provider Entry
                schema:
                  type: dict
                  attrs:
                    - variable: provider
                      label: Provider
                      schema:
                        type: string
                        required: true
                        enum:
                          - value: all
                            description: All providers
                          - value: ipify
                            description: ipify
                          - value: ifconfig
                            description: ifconfig
                          - value: ipinfo
                            description: ipinfo
                          - value: spdyn
                            description: spdyn
                          - value: ipleak
                            description: ipleak
                          - value: custom
                            description: Custom Provider
                    - variable: custom
                      label: Custom Value
                      schema:
                        type: string
                        show_if: [["provider", "=", "custom"]]
                        default: ""
                        required: true
        - variable: publicIpv4HttpProviders
          label: Public IPv4 HTTP Providers
          description: Providers to obtain the public IPv4 address
          schema:
            type: list
            min: 1
            required: true
            empty: false
            default: [{ "provider": "all", "custom": "" }]
            items:
              - variable: publicIpv4HttpProviderEntry
                label: Public IPv4 HTTP Provider Entry
                schema:
                  type: dict
                  attrs:
                    - variable: provider
                      label: Provider
                      schema:
                        type: string
                        required: true
                        enum:
                          - value: all
                            description: All providers
                          - value: ipleak
                            description: iplaek
                          - value: ipify
                            description: ipify
                          - value: custom
                            description: Custom Provider
                    - variable: custom
                      label: Custom Value
                      schema:
                        type: string
                        show_if: [["provider", "=", "custom"]]
                        default: ""
                        required: true
        - variable: publicIpv6HttpProviders
          label: Public IPv6 HTTP Providers
          description: Providers to obtain the public IPv6 address
          schema:
            type: list
            min: 1
            required: true
            empty: false
            default: [{ "provider": "all", "custom": "" }]
            items:
              - variable: publicIpv6HttpProviderEntry
                label: Public IPv6 HTTP Provider Entry
                schema:
                  type: dict
                  attrs:
                    - variable: provider
                      label: Provider
                      schema:
                        type: string
                        required: true
                        enum:
                          - value: all
                            description: All providers
                          - value: ipleak
                            description: ipleak
                          - value: ipify
                            description: ipify
                          - value: custom
                            description: Custom Provider
                    - variable: custom
                      label: Custom Value
                      schema:
                        type: string
                        show_if: [["provider", "=", "custom"]]
                        default: ""
                        required: true
        - variable: publicIpFetchers
          label: Public IP Fetchers
          description: Fetcher types to obtain the public IP address
          schema:
            type: list
            min: 1
            required: true
            empty: false
            default: [{ "provider": "all", "placeholder": "placeholder" }]
            items:
              - variable: publicIpFetcherEntry
                label: Public IP Fetcher Entry
                schema:
                  type: dict
                  attrs:
                    - variable: provider
                      label: Fetcher
                      schema:
                        type: string
                        required: true
                        enum:
                          - value: all
                            description: All providers
                          - value: http
                            description: HTTP
                          - value: dns
                            description: DNS
                    # Workaround for a UI bug that is fixed in the next release
                    # (Single items in a dict inside a list was getting converted to a list of strings)
                    - variable: placeholder
                      label: placeholder
                      schema:
                        type: string
                        default: placeholder
                        required: true
                        hidden: true

        - variable: additionalEnvs
          label: Additional Environment Variables
          description: Configure additional environment variables for DDNS Updater.
          schema:
            type: list
            default: []
            items:
              - variable: env
                label: Environment Variable
                schema:
                  type: dict
                  attrs:
                    - variable: name
                      label: Name
                      schema:
                        type: string
                        required: true
                    - variable: value
                      label: Value
                      schema:
                        type: string
                        required: true

  - variable: ddnsRunAs
    label: ""
    group: User and Group Configuration
    schema:
      type: dict
      attrs:
        - variable: user
          label: User ID
          description: The user id that DDNS Updater will run as.
          schema:
            type: int
            min: 2
            default: 568
            required: true
        - variable: group
          label: Group ID
          description: The group id that DDNS Updater will run as.
          schema:
            type: int
            min: 2
            default: 568
            required: true

  - variable: ddnsNetwork
    label: ""
    group: Network Configuration
    schema:
      type: dict
      attrs:
        - variable: webPort
          label: Web Port
          description: The port for the DDNS Updater Web UI.
          schema:
            type: int
            default: 30007
            min: 9000
            max: 65535
            required: true
        - variable: hostNetwork
          label: Host Network
          description: |
            Bind to the host network. It's recommended to keep this disabled.</br>
          schema:
            type: boolean
            default: false

  - variable: ddnsStorage
    label: ""
    group: Storage Configuration
    schema:
      type: dict
      attrs:
        - variable: data
          label: DDNS Updater Data Storage
          description: The path to store DDNS Updater Data.
          schema:
            type: dict
            attrs:
              - variable: type
                label: Type
                description: |
                  ixVolume: Is dataset created automatically by the system.</br>
                  Host Path: Is a path that already exists on the system.
                schema:
                  type: string
                  required: true
                  immutable: true
                  default: "ixVolume"
                  enum:
                    - value: "hostPath"
                      description: Host Path (Path that already exists on the system)
                    - value: "ixVolume"
                      description: ixVolume (Dataset created automatically by the system)
              - variable: datasetName
                label: Dataset Name
                schema:
                  type: string
                  show_if: [["type", "=", "ixVolume"]]
                  required: true
                  hidden: true
                  immutable: true
                  default: "data"
                  $ref:
                    - "normalize/ixVolume"
              - variable: hostPath
                label: Host Path
                schema:
                  type: hostpath
                  show_if: [["type", "=", "hostPath"]]
                  required: true

  - variable: resources
    group: Resources Configuration
    label: ""
    schema:
      type: dict
      attrs:
        - variable: limits
          label: Limits
          schema:
            type: dict
            attrs:
              - variable: cpu
                label: CPU
                description: CPU limit for DDNS Updater.
                schema:
                  type: string
                  max_length: 6
                  valid_chars: '^(0\.[1-9]|[1-9][0-9]*)(\.[0-9]|m?)$'
                  valid_chars_error: |
                    Valid CPU limit formats are</br>
                    - Plain Integer - eg. 1</br>
                    - Float - eg. 0.5</br>
                    - Milicpu - eg. 500m
                  default: "4000m"
                  required: true
              - variable: memory
                label: Memory
                description: Memory limit for DDNS Updater.
                schema:
                  type: string
                  max_length: 12
                  valid_chars: "^[1-9][0-9]*([EPTGMK]i?|e[0-9]+)?$"
                  valid_chars_error: |
                    Valid Memory limit formats are</br>
                    - Suffixed with E/P/T/G/M/K - eg. 1G</br>
                    - Suffixed with Ei/Pi/Ti/Gi/Mi/Ki - eg. 1Gi</br>
                    - Plain Integer in bytes - eg. 1024</br>
                    - Exponent - eg. 134e6
                  default: "8Gi"
                  required: true
