servername: 'http://local.phrasea/'
languages:
    available:
        - de
        - en
        - fr
        - nl
    default: 'en'
main:
    maintenance: false
    key: ''
    database:
        host: 'sql-host'
        port: 3306
        user: 'sql-user'
        password: 'sql-password'
        dbname: ab_phraseanet
        driver: pdo_mysql
        charset: UTF8
    database-test:
        driver: pdo_sqlite
        path: '/tmp/db.sqlite'
        charset: UTF8
    cache:
        type: ArrayCache
        options: {}
    search-engine:
        type: elasticsearch
        options:
            host: elasticsearch
            port: 9200
            index: ''
            shards: 3
            replicas: 0
            minScore: 2
            highlight: true
            maxResultWindow: 500000
            populate_order: MODIFICATION_DATE
            populate_direction: DESC
            populate_permalinks: false
            activeTab: '#elastic-search'
            facets:
                _base:
                    limit: 10
                _collection:
                    limit: 10
                _doctype:
                    limit: 10
                _camera_model:
                    limit: 10
                _iso:
                    limit: 0
                _aperture:
                    limit: 0
                _shutterspeed:
                    limit: 0
                _flashfired:
                    limit: 0
                _framerate:
                    limit: 0
                _audiosamplerate:
                    limit: 0
                _videocodec:
                    limit: 0
                _audiocodec:
                    limit: 0
                _orientation:
                    limit: 0
                _colorspace:
                    limit: 0
                _mimetype:
                    limit: 0
    task-manager:
        status: started
        enabled: true
        options:
            protocol: tcp
            host: 127.0.0.1
            port: 6660
            linger: 500
        logger:
            max-files: 10
            enabled: true
            level: INFO
    session:
        type: native
        options: []
        ttl: 86400
    binaries:
        ghostscript_binary: null
        php_binary: null
        unoconv_binary: null
        ffmpeg_binary: null
        ffprobe_binary: null
        mp4box_binary: null
        pdftotext_binary: null
        ffmpeg_timeout: 3600
        ffprobe_timeout: 60
        gs_timeout: 60
        mp4box_timeout: 60
        swftools_timeout: 60
        unoconv_timeout: 60
        exiftool_timeout: 60
    storage:
        subdefs: null
        cache: null
        log : null
        download: null
        lazaret: null
        caption: null
        worker_tmp_files: null

trusted-proxies: []
network-proxies:
    http-proxy:
        enabled: false
        host:
        port:
        user:
        password:
    ftp-proxy:
        enabled: false
        host:
        port:
        user:
        password:
debugger:
    allowed-ips: []
border-manager:
    enabled: true
    extension-mapping:
        otc: application/vnd.oasis.opendocument.chart-template
        ttc: application/x-font-ttf
        xlsx: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet
        docx: application/msword
        pptx: application/vnd.ms-powerpoint
        mxf: application/mxf
        mp4: video/mp4
        svg: image/svg+xml
    checkers:
        -
            type: Checker\Sha256
            enabled: true
        -
            type: Checker\UUID
            enabled: true
        -
            type: Checker\Colorspace
            enabled: false
            options:
                colorspaces: [cmyk, grayscale, rgb]
        -
            type: Checker\Dimension
            enabled: false
            options:
                width: 80
                height: 160
        -
            type: Checker\Extension
            enabled: false
            options:
                extensions: [jpg, jpeg, bmp, tif, gif, png, heic, pdf, doc, docx, xls, xlsx, odt, mpg, mpeg, mov, avi, mp3, mp2, mp4, m4v, m4a, mkv, hevc, aac, aiff, wav]
        -
            type: Checker\Filename
            enabled: false
            options:
                sensitive: true
        -
            type: Checker\MediaType
            enabled: false
            options:
                mediatypes: [Audio, Document, Image, Video]

registry:
    api-clients:
        api-subdef_service: false
    actions:
        export-stamp-choice: false
        stamp-subdefs: false
user_account:
    deleting_policies:
        email_confirmation: true
authentication:
    auto-create:
        templates: {  }
    providers:
        facebook:
            enabled: false
            display: false
            title: Facebook
            type: facebook
            options:
                app-id: ''
                secret: ''
                default-graph-version: 'v2.10'
        twitter:
            enabled: false
            display: false
            title: Twitter
            type: twitter
            options:
                consumer-key: ''
                consumer-secret: ''
        github:
            enabled: false
            display: false
            title: Github
            type: github
            options:
                client-id: ''
                client-secret: ''
        viadeo:
            enabled: false
            display: false
            title: Viadeo
            type: viadeo
            options:
                client-id: ''
                client-secret: ''
        linkedin:
            enabled: false
            display: false
            title: LinkedIN
            type: linkedin
            options:
                client-id: ''
                client-secret: ''
        openid-1:
            enabled: false
            display: false
            title: 'openid 1'
            type: openid
            options:
                client-id: ''
                client-secret: ''
                base-url: 'https://keycloak.phrasea.local'
                realm-name: phrasea
                exclusive: false
                icon-uri: null
                birth-group: _firstlog
                everyone-group: _everyone
                metamodel: _metamodel
                model-gpfx: _M_
                model-upfx: _U_
                debug: false
                auto-logout: false
                auto-connect-idp-name: null
registration-fields:
    -
        name: company
        required: true
    -
        name: lastname
        required: true
    -
        name: firstname
        required: true
    -
        name: geonameid
        required: true
download_async:
    enabled: false

xsendfile:
    enabled: false
    type: nginx
    mapping: []
h264-pseudo-streaming:
    enabled: false
    type: nginx
    mapping: []
plugins: []
api_cors:
  enabled: false
  allow_credentials: false
  allow_origin: []
  allow_headers: []
  allow_methods: []
  expose_headers: []
  max_age: 0
  hosts: []
session:
  idle: 0
  # 1 week
  lifetime: 604800
crossdomain:
  allow-access-from:
    -
      domain: '*.cooliris.com'
      secure: 'false'
embed_bundle:
    video:
        player: videojs
        autoplay: false
        cover_subdef: poster
        message_start: StartOfMessage
        available_speeds:
            - 1
            - 1.5
            - 3
    audio:
        player: videojs
        autoplay: false
        cover_subdef: thumbnail
    document:
        #player: flexpaper
        enable_pdfjs: true
geocoding-providers:
    -
        map-provider: 'mapboxWebGL'
        enabled: false
        public-key: ''
        map-layers:
            -
                name: Light
                value: 'mapbox://styles/mapbox/light-v9'
            -
                name: Streets
                value: 'mapbox://styles/mapbox/streets-v9'
            -
                name: Basic
                value: 'mapbox://styles/mapbox/basic-v9'
            -
                name: Satellite
                value: 'mapbox://styles/mapbox/satellite-v9'
            -
                name: Dark
                value: 'mapbox://styles/mapbox/dark-v9'
        transition-mapboxgl:
            -
                animate: true
                speed: '2.2'
                curve: '1.42'
        default-position:
            - 42.488
            - 3.779
        default-zoom: 2
        marker-default-zoom: 11
        position-fields:
            #-
            #   name: GpsCompositePosition
            #   type: latlng
            -
                name: Latitude
                type: lat
            -
                name: Longitude
                type: lon
        geonames-field-mapping: true
        cityfields: 'City, Ville'
        provincefields: Province
        countryfields: 'Country, Pays'
        latitudefields: Latitude
        longitudefields: Longitude
video-editor:
    ChapterVttFieldName: VideoTextTrackChapters
    seekBackwardStep: 500 # in ms
    seekForwardStep: 500  # in ms
    playbackRates:
        - 1
        - '1.5'
        - 3
workers:
    auto-cancelingJob: 24 # period in hours, not define or null to not execute
    queue:
        worker-queue:
            registry: alchemy_worker.queue_registry
            host: localhost
            port: 5672
            user: ''
            password: ''
            ssl: false
            vhost: /
            heartbeat: 60
    webhook:
        timeout: 30
        verify_ssl: true
    queues:
        assetsIngest:
            max_retry: 3
            ttl_retry: 10000
        createRecord:
            max_retry: 3
            ttl_retry: 10000
        editRecord:
            max_retry: 3
            ttl_retry: 10000
        exportMail:
            max_retry: 3
            ttl_retry: 10000
        downloadAsync:
            max_retry: 3
            ttl_retry: 10000
        exposeUpload:
            max_retry: 3
            ttl_retry: 10000
        ftp:
            max_retry: 3
            ttl_retry: 180000
        populateIndex:
            max_retry: 3
            ttl_retry: 10000
        pullAssets:
            max_retry: 3
            ttl_retry: 10000
        recordsActions:
            max_retry: 3
            ttl_retry: 10000
        shareBasket:
            max_retry: 3
            ttl_retry: 10000
        subdefCreation:
            max_retry: 3
            ttl_retry: 10000
            ttl_delayed: 5000
        validationReminder:
            max_retry: 3
            ttl_retry: 7200000
        webhook:
            max_retry: 3
            ttl_retry: 10000
        writeMetadatas:
            max_retry: 3
            ttl_retry: 10000
            ttl_delayed: 5000
    writeMetadatas:
        acceptedMimeType:
            - image/jpeg
            - image/png
            - application/postscript
            - application/pdf
            - image/tiff
externalservice:
    pusher:
        auth_key: 'pusher-auth_key'
        secret: 'pusher-secret'
        app_id: 'pusher-app_id'
    happyscribe:
        token: token
        organization_id: 123456
        transcript_format: vtt
        subdef_source: preview


Console_logger_enabled_environments: [test]

feedback-report:
    enabled: false
    actions:
        action_unvoted:
            status_bit: 8
            value: '{% if vote.votes_unvoted > 0 %} 1 {% else %} 0 {% endif %}'
        action_red:
            status_bit: 9
            value: '{% if vote.votes_no > 0 %} 1 {% else %} 0 {% endif %}'
        action_green:
            status_bit: 10
            value: '{% if vote.votes_no == 0 %} 1 {% else %} 0 {% endif %}'
        action_log:
            metadata: Validations
            method: prepend
            delimiter: "\n"
            value: 'Vote initated on {{ vote.created }} by {{ initiator ? initiator.getEmail() : "?" }} expired {{ vote.expired }} : {{ vote.voters_count }} participants, {{ vote.votes_unvoted }} unvoted, {{ vote.votes_no }} "no", {{ vote.votes_yes}} "yes".'

translator:
    jobs:
        #
        # - translate EN keywords to FR and EN
        #       nb: since we clean the destination fields, we MUST (re)write EN to EN
        # - add country to keywords, both FR/EN
        keywords:
            active: false
            databox: my_databox
            if_collection: to_translate
            if_status: x1xxxx
            actions:

                KeywordsENtoFREN:
                    active: true
                    source_field: KeywordsEN
                    source_lng: en
                    destination_fields:
                        - fr:keywordsFR
                        - en:keywordsEN
                    cleanup_source: if_translated
                    # action 1 cleans the destination fields
                    cleanup_destination: true

                CountryENtoKeywordsFREN:
                    active: true
                    source_field: CountryEN
                    source_lng: en
                    # add translated country to the keywords
                    destination_fields:
                        - fr:keywordsFR
                        - en:keywordsEN
                    cleanup_source: if_translated
                    # action 2 must NOT erase what action 1 did
                    cleanup_destination: false

            # end of job : change coll status
            set_status: 10xxxx
            set_collection: online
