sources:
  - type: swift
    name: !env '${UPLOAD_CONTAINER}'
    kwargs:
        username: !env '${OS_USERNAME}'
        password: !env '${OS_PASSWORD}'
        tenant_name: !env '${OS_TENANT_NAME}'
        tenant_id: !env '${OS_TENANT_ID}'
        region_name: !env '${OS_REGION_NAME}'
        auth_version: !env '${ST_AUTH_VERSION}'
        auth_url: !env '${OS_AUTH_URL}'
        auth_url_short: !env '${OS_AUTH_URL_SHORT}'
        user_domain_name: !env '${OS_USER_DOMAIN_NAME}'
        container: !env '${UPLOAD_CONTAINER}'

schemes:
  - type: gsc
    kwargs:
      level_re: '([A-Z0-9-_]+)/.*'

backends:
  - type: eoxserver
    filter:
    kwargs:
      instance_base_path: !env '${INSTALL_DIR}'
      instance_name: !env '${INSTANCE_NAME}'
      mapping:
        DEM1:
          COP-DEM_EEA-10-DGED:
            product_type_name: !env '${COLLECTION}_Product_COP-DEM_EEA-10-DGED'
            collections:
              - !env '${COLLECTION}'
              - !env '${COLLECTION}_COP-DEM_EEA-10-DGED'
            coverages:
              DEM1: float32_grayscale
          COP-DEM_EEA-10-INSP:
            product_type_name: !env '${COLLECTION}_Product_COP-DEM_EEA-10-INSP'
            collections:
              - !env '${COLLECTION}'
              - !env '${COLLECTION}_COP-DEM_EEA-10-INSP'
            coverages:
              DEM1: float32_grayscale
          COP-DEM_GLO-30-DGED:
            product_type_name: !env '${COLLECTION}_Product_COP-DEM_GLO-30-DGED'
            collections:
              - !env '${COLLECTION}'
              - !env '${COLLECTION}_COP-DEM_GLO-30-DGED'
            coverages:
              DEM1: float32_grayscale
          COP-DEM_GLO-90-DGED:
            product_type_name: !env '${COLLECTION}_Product_COP-DEM_GLO-90-DGED'
            collections:
              - !env '${COLLECTION}'
              - !env '${COLLECTION}_COP-DEM_GLO-90-DGED'
            coverages:
              DEM1: float32_grayscale
          COP-DEM_GLO-30-DTED:
            product_type_name: !env '${COLLECTION}_Product_COP-DEM_GLO-30-DTED'
            collections:
              - !env '${COLLECTION}'
              - !env '${COLLECTION}_COP-DEM_GLO-30-DTED'
            coverages:
              DEM1: int16_grayscale
          COP-DEM_GLO-90-DTED:
            product_type_name: !env '${COLLECTION}_Product_COP-DEM_GLO-90-DTED'
            collections:
              - !env '${COLLECTION}'
              - !env '${COLLECTION}_COP-DEM_GLO-90-DTED'
            coverages:
              DEM1: int16_grayscale

post_handlers:
  - path: registrar.post_handlers.ReportingPostHandler
    kwargs:
      service_url: dem.pass.copernicus.eu
      reporting_dir: /mnt/reports/
