-
Notifications
You must be signed in to change notification settings - Fork 3
/
Dockerfile.3.7.4
43 lines (31 loc) · 1.82 KB
/
Dockerfile.3.7.4
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
FROM microsoft/windowsservercore:1709 as root
LABEL maintainer="muller.john@gmail.com"
ENV RMQ_VERSION="3.7.4" \
rabbit_download_url="https://github.com/rabbitmq/rabbitmq-server/releases/download/v3.7.4/rabbitmq-server-windows-3.7.4.zip"
# setup powershell options for RUN commands
SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"]
# download and extract rabbitmq, and remove zip file when done
RUN [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12; \
Invoke-WebRequest -Uri $env:rabbit_download_url -OutFile rabbitmq.zip ; \
Expand-Archive -Path .\rabbitmq.zip -DestinationPath "c:\\" ; \
Remove-Item -Force rabbitmq.zip; \
Rename-Item c:\rabbitmq_server-$env:RMQ_VERSION c:\rabbitmq
FROM gsxsolutions/erlang-otp-nano:20.3
LABEL maintainer="muller.john@gmail.com"
COPY --from=root c:\\rabbitmq c:\\rabbitmq
# tell rabbitmq where to find our custom config file
ENV RABBITMQ_CONFIG_FILE="c:\rabbitmq" \
RABBITMQ_BASE="c:\\rmq-data"
VOLUME ${RABBITMQ_BASE}
COPY start.cmd c:\\scripts\\start.cmd
RUN ["cmd", "/c", "echo [{rabbit, [{loopback_users, []}]}].> c:\\rabbitmq.config"]
RUN mkdir c:\Users\%USERNAME%\\AppData\\Roaming\\RabbitMQ
# Ports
# 4369: epmd, a peer discovery service used by RabbitMQ nodes and CLI tools
# 5672: used by AMQP 0-9-1 and 1.0 clients without TLS
# 5671: used by AMQP 0-9-1 and 1.0 clients with TLS
# 25672: used by Erlang distribution for inter-node and CLI tools communication and is allocated from a dynamic range (limited to a single port by default, computed as AMQP port + 20000).
# 15672: HTTP API clients and rabbitmqadmin (only if the management plugin is enabled)
EXPOSE 4369 5671 5672 25672 15672
# run server when container starts - container will shutdown when this process ends
CMD Scripts\\start.cmd