version: '2.1'
services:
  onlyoffice-documentserver:
    container_name: onlyoffice-documentserver
    build:
      context: ../.
    environment:
      - AMQP_SERVER_TYPE=${AMQP_SERVER_TYPE:-rabbitmq}
      - AMQP_SERVER_URL=${AMQP_SERVER_URL:-amqp://guest:guest@onlyoffice-rabbitmq}
    stdin_open: true
    restart: always
    ports:
      - '80:80'
      - '443:443'
    networks:
      - onlyoffice

  onlyoffice-rabbitmq:
    container_name: onlyoffice-rabbitmq
    image: rabbitmq
    restart: always
    networks:
     - onlyoffice
    expose:
      - '5672'

networks:
  onlyoffice:
    driver: 'bridge'
