Requirements:
# RabbitMQ
docker pull rabbitmq:3-management
docker create --name rabbitmq -p 5672:5672 -p 15672:15672 rabbitmq:3-management
docker start rabbitmq
# Producer
docker build --tag 'producer:latest' .
docker create --name producer --link rabbitmq producer:latest
docker start producer
RabbitMQ admin: http://localhost:15672 - login:
guest
- password:guest
nvm use
npm install
npm start
RabbitMQ is required to work on port
5672
The following environments variables are available to configure the producer
worker.
N
[=10] - Total number of drivers.GROWTH
[=1000] - Growth interval (ms)UNTRUSTWORTHY_DRIVERS_RATIO
[=0.05] - ratio of drivers that will not sent all their position messages
docker stop producer rabbitmq
docker rm producer rabbitmq producer_rabbitmq_1
docker rmi -f producer:latest rabbitmq:3-management