You can use the official Docker Image of Apache ActiveMQ Artemis at https://hub.docker.com/r/apache/activemq-artemis.
The contents of our docker-compose.yaml file to install ActiveMQ Artemis with Docker Compose will be as follows:
1 2 3 4 5 6 7 8 9 10 |
services: activemq-artemis: image: apache/activemq-artemis:latest container_name: 'activemq-artemis' ports: - 61616:61616 - 8161:8161 volumes: - ./activemq_data:/data/activemq - ./activemq_log:/var/log/activemq |
The 2 default ports of ActiveMQ Artemis and Artemis Console, we need to expose them to the outside to be able to use them! In addition, you should also mount 2 folders inside the ActiveMQ Artemis container, which are /data/activemq and /var/log/activemq, so that we can easily work with them.
The result when running the command “docker compose up” in the folder containing the docker-compose.yaml file with the above content is as follows:
So we have started an ActiveMQ Artemis server with Artemis Console!
Now you can access Artemis Console using the address http://localhost:8161/:
Log in with username and password artemis, you will see the following result: