language: generic

dist: trusty

env:
  # community edition
  - config: standalone.yml

  # integration edition
  - config: standalone.yml
    PRODUCT_NAME: documentserver-ie


  # certificates (default tls if onlyoffice not exists)
  - config: certs.yml
    ssl: true

  # certificates (default onlyoffice if exists)
  - config: certs.yml
    ssl: true
    private_key: onlyoffice.key
    certificate_request: onlyoffice.csr
    certificate: onlyoffice.crt

  # custom certificates
  - config: certs-customized.yml
    ssl: true
    private_key: mycert.key
    certificate_request: mycert.csr
    certificate: mycert.crt
    SSL_CERTIFICATE_PATH: /var/www/onlyoffice/Data/certs/mycert.crt
    SSL_KEY_PATH: /var/www/onlyoffice/Data/certs/mycert.key


  # postgresql 16
  - config: postgres.yml
    POSTGRES_VERSION: 16

  # postgresql 15
  - config: postgres.yml
    POSTGRES_VERSION: 15

  # postgresql 14
  - config: postgres.yml
    POSTGRES_VERSION: 14

  # postgresql 13
  - config: postgres.yml
    POSTGRES_VERSION: 13

  # postgresql 12
  - config: postgres.yml

  # postgresql custom values
  - config: postgres.yml
    DB_NAME: mydb
    DB_USER: myuser
    DB_PWD: password
    POSTGRES_DB: mydb
    POSTGRES_USER: myuser

  # postgresql deprecated variables
  - config: postgres-old.yml


  # mysql 8
  - config: mysql.yml
    MYSQL_VERSION: 8

  # mysql 5
  - config: mysql.yml
    MYSQL_VERSION: 5

  # mysql 5.7
  - config: mysql.yml


  # mariadb 10
  - config: mariadb.yml
    MARIADB_VERSION: 10

  # mariadb 10.5
  - config: mariadb.yml


  - config: activemq.yml
    ACTIVEMQ_VERSION: latest

  # activemq 5.14.3
  - config: activemq.yml


  # rabbitmq latest
  - config: rabbitmq.yml

  # rabbitmq 3
  - config: rabbitmq.yml
    RABBITMQ_VERSION: 3

  # rabbitmq old variables
  - config: rabbitmq-old.yml


  # redis latest with community edition
  - config: redis.yml

  # redis latest with integraion edition
  - config: redis.yml
    PRODUCT_NAME: documentserver-ie

  # redis 6
  - config: redis.yml
    REDIS_VERSION: 6

  # redis 5
  - config: redis.yml
    REDIS_VERSION: 5


  # graphite
  - config: graphite.yml

services:
  - docker

script:
  # Go to tests dir
  - cd ${PWD}/tests

  # Run test.
  - ./test.sh
