# Include{groups}
portals:
  open:
# Include{portalLink}
questions:
# Include{global}
# Include{workload}
# Include{workloadDeployment}

# Include{replicas1}
# Include{podSpec}
# Include{containerMain}
# Include{containerBasic}
# Include{containerAdvanced}

  - variable: env
    group: App Configuration
    label: Image Environment
    schema:
      additional_attrs: true
      type: dict
      attrs:
        - variable: original
          label: Original Server Settings
          schema:
            type: boolean
            default: true
            show_subquestions_if: true
            subquestions:
              - variable: ORIGIN_URL
                label: Origin Url
                schema:
                  type: string
                  required: true
                  default: ""
              - variable: ORIGIN_USERNAME
                label: Origin Username
                schema:
                  type: string
                  required: true
                  default: ""
              - variable: ORIGIN_PASSWORD
                label: Origin Password
                schema:
                  type: string
                  required: true
                  private: true
                  default: ""
        - variable: replica
          label: Replica Server Settings
          schema:
            type: boolean
            default: true
            show_subquestions_if: true
            subquestions:
              - variable: REPLICA_URL
                label: Replica Url
                schema:
                  type: string
                  required: true
                  default: ""
              - variable: REPLICA_USERNAME
                label: Replica Username
                schema:
                  type: string
                  required: true
                  default: ""
              - variable: REPLICA_PASSWORD
                label: Replica Password
                schema:
                  type: string
                  required: true
                  private: true
                  default: ""
              - variable: REPLICA_AUTOSETUP
                label: Replica Auto Setup
                schema:
                  type: boolean
                  default: false
              - variable: REPLICA_INTERFACENAME
                label: Replica Interface Name
                schema:
                  type: string
                  default: ""
        - variable: CRON
          label: CRON
          description: Set a cron task.
          schema:
            type: string
            default: "*/10 * * * *"
        - variable: RUNONSTART
          label: Run On Start
          schema:
            type: boolean
            default: true
        - variable: sync
          label: Sync Features Settings
          schema:
            type: boolean
            default: false
            show_subquestions_if: true
            subquestions:
              - variable: FEATURES_GENERALSETTINGS
                label: Features General Settings
                schema:
                  type: boolean
                  default: true
              - variable: FEATURES_QUERYLOGCONFIG
                label: Features Query Log Config
                schema:
                  type: boolean
                  default: true
              - variable: FEATURES_STATSCONFIG
                label: Features Stats Config
                schema:
                  type: boolean
                  default: true
              - variable: FEATURES_CLIENTSETTINGS
                label: Features Clients Settings
                schema:
                  type: boolean
                  default: true
              - variable: FEATURES_SERVICES
                label: Features Services
                schema:
                  type: boolean
                  default: true
              - variable: FEATURES_FILTERS
                label: Features Filters
                schema:
                  type: boolean
                  default: true
              - variable: FEATURES_DHCP_SERVERCONFIG
                label: Features DHCP Server Config
                schema:
                  type: boolean
                  default: true
              - variable: FEATURES_DHCP_STATICLEASES
                label: Features DHCP Static Leases
                schema:
                  type: boolean
                  default: true
              - variable: FEATURES_DNS_SERVERCONFIG
                label: Features DNS Server Config
                schema:
                  type: boolean
                  default: true
              - variable: FEATURES_DNS_ACCESSLISTS
                label: Features DNS Access Lists
                schema:
                  type: boolean
                  default: true
              - variable: FEATURES_DNS_REWRITES
                label: Features DNS Rewrites
                schema:
                  type: boolean
                  default: true
# Include{containerConfig}
# Include{serviceRoot}
        - variable: main
          label: Main Service
          description: The Primary service on which the healthcheck runs, often the webUI
          schema:
            additional_attrs: true
            type: dict
            attrs:
# Include{serviceSelectorLoadBalancer}
# Include{serviceSelectorExtras}
                    - variable: main
                      label: Main Service Port Configuration
                      schema:
                        additional_attrs: true
                        type: dict
                        attrs:
                          - variable: port
                            label: Port
                            description: This port exposes the container port on the service
                            schema:
                              type: int
                              default: 8080
                              required: true
# Include{serviceExpertRoot}
# Include{serviceExpert}
# Include{serviceList}
# Include{persistenceList}
# Include{ingressRoot}
        - variable: main
          label: Main Ingress
          schema:
            additional_attrs: true
            type: dict
            attrs:
# Include{ingressDefault}
# Include{ingressTLS}
# Include{ingressTraefik}
# Include{ingressAdvanced}
# Include{ingressList}

# Include{podSecurityContextRoot}
        - variable: runAsUser
          label: runAsUser
          description: The UserID of the user running the application
          schema:
            type: int
            default: 0
        - variable: runAsGroup
          label: runAsGroup
          description: The groupID this App of the user running the application
          schema:
            type: int
            default: 0
# Include{securityContextContainer}
# Include{securityContextAdvanced}
# Include{securityContextPod}
        - variable: fsGroup
          label: fsGroup
          description: The group that should own ALL storage.
          schema:
            type: int
            default: 568

# Include{resources}
# Include{advanced}
# Include{addons}
# Include{codeserver}
# Include{netshoot}
# Include{vpn}
# Include{documentation}
