Rename AMQP_SERVER_ENGINE->AMQP_SERVER_TYPE

This commit is contained in:
Alexey Golubev 2019-03-05 18:12:54 +03:00 committed by Alexey Golubev
parent 88f33c5d8f
commit ad4b496181
3 changed files with 5 additions and 5 deletions

View file

@ -168,7 +168,7 @@ Below is the complete list of parameters that can be set using environment varia
- **POSTGRESQL_SERVER_USER**: The new user name with superuser permissions for the PostgreSQL account.
- **POSTGRESQL_SERVER_PASS**: The password set for the PostgreSQL account.
- **AMQP_SERVER_URL**: The [AMQP URL](http://www.rabbitmq.com/uri-spec.html "RabbitMQ URI Specification") to connect to message broker server.
- **AMQP_SERVER_ENGINE**: The message broker engine. Supported values are 'rabbitmq' or 'activemq'. Defaults to 'rabbitmq'.
- **AMQP_SERVER_TYPE**: The message broker engine. 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_PORT**: The Redis server port number.
- **NGINX_WORKER_PROCESSES**: Defines the number of nginx worker processes.

View file

@ -5,7 +5,7 @@ services:
image: onlyoffice/4testing-documentserver-ie:latest
environment:
- AMQP_SERVER_URL=amqp://guest:guest@onlyoffice-activemq
- AMQP_SERVER_ENGINE=activemq
- AMQP_SERVER_TYPE=activemq
stdin_open: true
restart: always
ports:

View file

@ -64,7 +64,7 @@ read_setting(){
RABBITMQ_SERVER_URL=${RABBITMQ_SERVER_URL:-$(${JSON} rabbitmq.url)}
AMQP_SERVER_URL=${AMQP_SERVER_URL:-${RABBITMQ_SERVER_URL}}
AMQP_SERVER_ENGINE=${AMQP_SERVER_ENGINE:-rabbitmq}
AMQP_SERVER_TYPE=${AMQP_SERVER_TYPE:-rabbitmq}
parse_rabbitmq_url ${AMQP_SERVER_URL}
REDIS_SERVER_HOST=${REDIS_SERVER_HOST:-$(${JSON} services.CoAuthoring.redis.host)}
@ -144,12 +144,12 @@ update_postgresql_settings(){
}
update_rabbitmq_setting(){
if [ "${AMQP_SERVER_ENGINE}" == "rabbitmq" ]; then
if [ "${AMQP_SERVER_TYPE}" == "rabbitmq" ]; then
${JSON} -I -e "this.rabbitmq.url = '${RABBITMQ_SERVER_URL}'"
sed 's/\(exports\.USE_RABBIT_MQ = \).*\(;\)/'"\1true\2"'/' -i ${APP_DIR}/server/Common/sources/constants.js
fi
if [ "${AMQP_SERVER_ENGINE}" == "activemq" ]; then
if [ "${AMQP_SERVER_TYPE}" == "activemq" ]; then
${JSON} -I -e "if(this.activemq===undefined)this.activemq={};"
${JSON} -I -e "if(this.activemq.connectOptions===undefined)this.activemq.connectOptions={};"