FROM ubuntu:bionic
EXPOSE 2224
ARG HACLUSTER_PASS
RUN apt-get update \
; apt-get -y install systemd tzdata \
; ln -fs /usr/share/zoneinfo/Europe/Athens /etc/localtime && dpkg-reconfigure -f noninteractive tzdata \
; apt-get -y install pcs fence-agents resource-agents \
; apt-get -y autoclean
RUN (echo ${HACLUSTER_PASS}; echo ${HACLUSTER_PASS}) | passwd hacluster
CMD ["/lib/systemd/systemd", "--system"]
The above creates a base docker container of the Pacemaker Cluster Manager
on Ubunt::Bionic
.
Note: Change Europe/Athens
according to your timezone.
docker build --rm --build-arg 'HACLUSTER_PASS=<YourSecurePAssword>' -f 'pathTo/Dockefile' -t pcs:latest .
docker run -d --rm --privileged --name pcs --net host -p 2224:2224 pcs