---
- include: /usr/share/ansible/openshift-ansible/playbooks/byo/config.yml
  vars:
    debug_level: 2
    openshift_debug_level: "{{ debug_level }}"
    openshift_node_debug_level: "{{ node_debug_level | default(debug_level, true) }}"
    osm_controller_args:
      cloud-provider:
      - "aws"
    osm_api_server_args:
      cloud-provider:
      - "aws"
    openshift_node_kubelet_args:
      cloud-provider:
      - "aws"
      node-labels:
      - "role={{ openshift_node_labels.role }}"
    openshift_master_debug_level: "{{ master_debug_level | default(debug_level, true) }}"
    openshift_master_access_token_max_seconds: 2419200
    openshift_master_api_port: "{{ console_port }}"
    openshift_master_console_port: "{{ console_port | default (443) }}"
    osm_cluster_network_cidr: 172.16.0.0/16
    openshift_registry_selector: "role=infra"
    openshift_router_selector: "role=infra"
    openshift_hosted_router_replicas: 3
    openshift_hosted_registry_replicas: 3
    openshift_master_cluster_method: native
    openshift_node_local_quota_per_fsgroup: 512Mi
    openshift_clusterid: "{{ stack_name }}"
    openshift_cloudprovider_aws_single_cluster: false
    openshift_cloudprovider_kind: aws
    openshift_master_cluster_hostname: "internal-openshift-master.{{ public_hosted_zone }}"
    openshift_master_cluster_public_hostname: "openshift-master.{{ public_hosted_zone }}"
    osm_default_subdomain: "{{ wildcard_zone }}"
    openshift_master_default_subdomain: "{{osm_default_subdomain}}"
    osm_default_node_selector: "role=app"
    deployment_type: openshift-enterprise
    os_sdn_network_plugin_name: "{{ openshift_sdn }}"
    openshift_master_identity_providers:
    - name: github
      kind: GitHubIdentityProvider
      login: true
      challenge: false
      mapping_method: claim
      clientID: "{{ github_client_id }}"
      clientSecret: "{{ github_client_secret }}"
      organizations: "{{ github_organization }}"
    osm_use_cockpit: true
    containerized: false
    # registry
    openshift_hosted_registry_storage_kind: object
    openshift_hosted_registry_storage_provider: s3
    openshift_hosted_registry_storage_s3_accesskey: "{{ hostvars['localhost']['s3user_id'] }}"
    openshift_hosted_registry_storage_s3_secretkey: "{{ hostvars['localhost']['s3user_secret'] }}"
    openshift_hosted_registry_storage_s3_bucket: "{{ hostvars['localhost']['s3_bucket_name'] }}"
    openshift_hosted_registry_storage_s3_region: "{{ hostvars['localhost']['region'] }}"
    openshift_hosted_registry_storage_s3_chunksize: 26214400
    openshift_hosted_registry_storage_s3_rootdirectory: /registry
    openshift_hosted_registry_pullthrough: true
    openshift_hosted_registry_acceptschema2: true
    openshift_hosted_registry_enforcequota: true
    # metrics
    openshift_hosted_metrics_storage_kind: dynamic
    openshift_hosted_metrics_storage_volume_size: "{{ openshift_hosted_metrics_storage_volume_size }}"
    openshift_metrics_hawkular_nodeselector: {"role":"infra"}
    openshift_metrics_cassandra_nodeselector: {"role":"infra"}
    openshift_metrics_heapster_nodeselector: {"role":"infra"}

    # logging
    openshift_logging_es_pvc_dynamic: true
    openshift_logging_es_pvc_size: "{{ openshift_hosted_logging_storage_volume_size }}"
    openshift_logging_es_cluster_size: 3
    openshift_logging_es_nodeselector: {"role":"infra"}
    openshift_logging_kibana_nodeselector: {"role":"infra"}
    openshift_logging_curator_nodeselector: {"role":"infra"}
