Change several names

This commit is contained in:
Roman 2019-12-20 14:56:18 +03:00
parent 181b6f9c8f
commit 0ab9e7f144
8 changed files with 39 additions and 27 deletions

View file

@ -30,13 +30,18 @@ env:
# activemq # activemq
- config: activemq.yml - config: activemq.yml
AMQP_SERVER_TYPE: activemq
AMQP_SERVER_URL: amqp://guest:guest@onlyoffice-activemq
# amqp variables
- config: amqp.yml
AMQP_TYPE: activemq AMQP_TYPE: activemq
AMQP_URL: amqp://guest:guest@onlyoffice-activemq AMQP_URI: amqp://guest:guest@onlyoffice-activemq
# rabbitmq
- config: rabbitmq.yml
AMQP_TYPE: rabbitmq
AMQP_URI: amqp://guest:guest@onlyoffice-rabbitmq
# rabbitmq old variables
- config: rabbitmq-old.yml
AMQP_SERVER_TYPE: rabbitmq
AMQP_SERVER_URL: amqp://guest:guest@onlyoffice-rabbitmq
services: services:
- docker - docker

View file

@ -168,7 +168,7 @@ Below is the complete list of parameters that can be set using environment varia
- **DB_NAME**: The name of a database to be created on the image startup. - **DB_NAME**: The name of a database to be created on the image startup.
- **DB_USER**: The new user name with superuser permissions for the database account. - **DB_USER**: The new user name with superuser permissions for the database account.
- **DB_PWD**: The password set for the database account. - **DB_PWD**: The password set for the database account.
- **AMQP_URL**: The [AMQP URL](http://www.rabbitmq.com/uri-spec.html "RabbitMQ URI Specification") to connect to message broker server. - **AMQP_URI**: The [AMQP URL](http://www.rabbitmq.com/uri-spec.html "RabbitMQ URI Specification") to connect to message broker server.
- **AMQP_TYPE**: The message broker type. Supported values are `rabbitmq` or `activemq`. Defaults to `rabbitmq`. - **AMQP_TYPE**: The message broker type. Supported values are `rabbitmq` or `activemq`. Defaults to `rabbitmq`.
- **REDIS_SERVER_HOST**: The IP address or the name of the host where the Redis server is running. - **REDIS_SERVER_HOST**: The IP address or the name of the host where the Redis server is running.
- **REDIS_SERVER_PORT**: The Redis server port number. - **REDIS_SERVER_PORT**: The Redis server port number.

View file

@ -10,7 +10,7 @@ services:
- DB_PORT=5432 - DB_PORT=5432
- DB_NAME=onlyoffice - DB_NAME=onlyoffice
- DB_USER=onlyoffice - DB_USER=onlyoffice
- AMQP_URL=amqp://guest:guest@onlyoffice-rabbitmq - AMQP_URI=amqp://guest:guest@onlyoffice-rabbitmq
- REDIS_SERVER_HOST=onlyoffice-redis - REDIS_SERVER_HOST=onlyoffice-redis
- REDIS_SERVER_PORT=6379 - REDIS_SERVER_PORT=6379
# Uncomment strings below to enable the JSON Web Token validation. # Uncomment strings below to enable the JSON Web Token validation.

View file

@ -87,9 +87,9 @@ read_setting(){
DB_TYPE=${DB_TYPE:-$(${JSON} services.CoAuthoring.sql.type)} DB_TYPE=${DB_TYPE:-$(${JSON} services.CoAuthoring.sql.type)}
RABBITMQ_SERVER_URL=${RABBITMQ_SERVER_URL:-$(${JSON} rabbitmq.url)} RABBITMQ_SERVER_URL=${RABBITMQ_SERVER_URL:-$(${JSON} rabbitmq.url)}
AMQP_URL=${AMQP_URL:-${AMQP_SERVER_URL:-${RABBITMQ_SERVER_URL}}} AMQP_URI=${AMQP_URI:-${AMQP_SERVER_URL:-${RABBITMQ_SERVER_URL}}}
AMQP_TYPE=${AMQP_TYPE:-${AMQP_SERVER_TYPE:-rabbitmq}} AMQP_TYPE=${AMQP_TYPE:-${AMQP_SERVER_TYPE:-rabbitmq}}
parse_rabbitmq_url ${AMQP_URL} parse_rabbitmq_url ${AMQP_URI}
REDIS_SERVER_HOST=${REDIS_SERVER_HOST:-$(${JSON} services.CoAuthoring.redis.host)} REDIS_SERVER_HOST=${REDIS_SERVER_HOST:-$(${JSON} services.CoAuthoring.redis.host)}
REDIS_SERVER_PORT=${REDIS_SERVER_PORT:-6379} REDIS_SERVER_PORT=${REDIS_SERVER_PORT:-6379}
@ -179,7 +179,7 @@ update_rabbitmq_setting(){
if [ "${AMQP_TYPE}" == "rabbitmq" ]; then if [ "${AMQP_TYPE}" == "rabbitmq" ]; then
${JSON} -I -e "if(this.queue===undefined)this.queue={};" ${JSON} -I -e "if(this.queue===undefined)this.queue={};"
${JSON} -I -e "this.queue.type = 'rabbitmq'" ${JSON} -I -e "this.queue.type = 'rabbitmq'"
${JSON} -I -e "this.rabbitmq.url = '${AMQP_URL}'" ${JSON} -I -e "this.rabbitmq.url = '${AMQP_URI}'"
fi fi
if [ "${AMQP_TYPE}" == "activemq" ]; then if [ "${AMQP_TYPE}" == "activemq" ]; then

View file

@ -4,8 +4,8 @@ services:
container_name: onlyoffice-documentserver container_name: onlyoffice-documentserver
image: onlyoffice/4testing-documentserver-ie:latest image: onlyoffice/4testing-documentserver-ie:latest
environment: environment:
- AMQP_SERVER_TYPE - AMQP_TYPE
- AMQP_SERVER_URL - AMQP_URI
stdin_open: true stdin_open: true
restart: always restart: always
ports: ports:

View file

@ -7,7 +7,7 @@ DB_NAME=onlyoffice
DB_USER=onlyoffice DB_USER=onlyoffice
DB_PWD=onlyoffice DB_PWD=onlyoffice
AMQP_TYPE=rabbitmq AMQP_TYPE=rabbitmq
AMQP_URL=amqp://guest:guest@onlyoffice-rabbitmq AMQP_URI=amqp://guest:guest@onlyoffice-rabbitmq
REDIS_SERVER_HOST=onlyoffice-redis REDIS_SERVER_HOST=onlyoffice-redis
REDIS_SERVER_PORT=6379 REDIS_SERVER_PORT=6379
JWT_ENABLED=true JWT_ENABLED=true

19
tests/rabbitmq-old.yml Normal file
View file

@ -0,0 +1,19 @@
version: '2'
services:
onlyoffice-documentserver:
container_name: onlyoffice-documentserver
image: onlyoffice/4testing-documentserver-ie:latest
environment:
- AMQP_SERVER_TYPE
- AMQP_SERVER_URL
stdin_open: true
restart: always
ports:
- '80:80'
- '443:443'
networks:
- onlyoffice
networks:
onlyoffice:
driver: 'bridge'

View file

@ -5,7 +5,7 @@ services:
image: onlyoffice/4testing-documentserver-ie:latest image: onlyoffice/4testing-documentserver-ie:latest
environment: environment:
- AMQP_TYPE - AMQP_TYPE
- AMQP_URL - AMQP_URI
stdin_open: true stdin_open: true
restart: always restart: always
ports: ports:
@ -14,18 +14,6 @@ services:
networks: networks:
- onlyoffice - onlyoffice
onlyoffice-activemq:
container_name: onlyoffice-activemq
image: webcenter/activemq:5.14.3
environment:
- ACTIVEMQ_USERS_guest
- ACTIVEMQ_GROUPS_owners
restart: always
networks:
- onlyoffice
expose:
- '5672'
networks: networks:
onlyoffice: onlyoffice:
driver: 'bridge' driver: 'bridge'