I am trying to implement SSL certificate in my ActiveMQ Artemis docker image in on-prem server. I have modified the broker.xml
and dockerfile
to implement the change in the image, but whenever I am trying to run the image, it is throwing me error:
CREATE_ARGUMENTS=--user username --password password --silent --require-login --http-host 0.0.0.0 --relax-jolokia
broker already created, ignoring creation
Running sed command
sed: can't read /var/lib/artemis-instance/etc/artemis.profile: No such file or directory
Dockerfile:
RUN mkdir /var/lib/artemis-instance
RUN mkdir -p /etc/certs/
RUN chmod 755 /var/lib/artemis-instance
RUN rm -rf /var/lib/artemis-instance/etc/broker.xml; ln -s artemis.profile /var/lib/artemis-instance/etc/artemis.profile
COPY broker.xml /var/lib/artemis-instance/etc/broker.xml
COPY ./docker-run.sh /
broker.xml
(have changed only in acceptors):
<!-- STOMP Acceptor. -->
<acceptor name="stomp">tcp://0.0.0.0:61613?tcpSendBufferSize=1048576;tcpReceiveBufferSize=1048576;protocols=STOMP;useEpoll=true</acceptor>
<!-- HornetQ Compatibility Acceptor. Enables HornetQ Core and STOMP for legacy HornetQ clients. -->
<acceptor name="hornetq">tcp://0.0.0.0:5445?anycastPrefix=jms.queue.;multicastPrefix=jms.topic.;protocols=HORNETQ,STOMP;useEpoll=true</acceptor>
<!-- MQTT Acceptor -->
<acceptor name="mqtt">tcp://0.0.0.0:1883?tcpSendBufferSize=1048576;tcpReceiveBufferSize=1048576;protocols=MQTT;useEpoll=true;sslEnabled=true;keyStorePath=/var/lib/artemis-instance/etc/certs/;keyStorePassword=password;needClientAuth=true </acceptor>
</acceptors>