## Based on cyclos/cyclos:4.14
docker-image: docker.0k.io/cyclos:4.14.17
config-resources:
  - /usr/local/cyclos/WEB-INF/classes/cyclos.properties
data-resources:
  - /var/log/cyclos

provides:
  cyclos-server:

default-options:

uses:
  postgres-database:
    #constraint: required | recommended | optional
    #auto: pair | summon | none ## default: pair
    constraint: required
    auto: summon
    solves:
      database: "main storage"
    default-options:
      extensions:
        - cube
        - earthdistance
        - postgis
        - unaccent
      init-sql: !bash-stdout |
        zcat "$BASE_CHARM_PATH/src/init.sql.gz"
  log-rotate:
    #constraint: required | recommended | optional
    #auto: pair | summon | none ## default: pair
    constraint: recommended
    auto: pair
    solves:
      unmanaged-logs: "in docker logs"
    #default-options:
  web-proxy:
    #constraint: required | recommended | optional
    #auto: pair | summon | none ## default: pair
    constraint: recommended
    auto: pair
    solves:
      proxy: "Public access"
    default-options:
      target: !var-expand ${MASTER_BASE_SERVICE_NAME}:8080