tacticalrmm/docker/salt/dockerfile

24 lines
935 B
Plaintext
Raw Normal View History

2020-04-06 18:21:52 +00:00
FROM ubuntu:18.04
ARG SALT_USER
ARG SALT_PASS
RUN adduser --no-create-home --disabled-password --gecos "" ${SALT_USER} && \
2020-04-06 18:21:52 +00:00
echo "${SALT_USER}:${SALT_PASS}" | chpasswd && \
apt-get update && \
apt-get install -y ca-certificates wget gnupg2 gettext-base tzdata supervisor && \
2020-04-11 06:11:00 +00:00
wget -O - https://repo.saltstack.com/py3/ubuntu/18.04/amd64/latest/SALTSTACK-GPG-KEY.pub | apt-key add - && \
echo 'deb http://repo.saltstack.com/py3/ubuntu/18.04/amd64/latest bionic main' | tee /etc/apt/sources.list.d/saltstack.list && \
2020-04-06 18:21:52 +00:00
apt-get update && \
apt-get install -y salt-master salt-api && \
mkdir -p /var/log/supervisor
2020-04-06 18:21:52 +00:00
COPY ./docker/salt/api.conf /etc/salt/master.tmp
RUN envsubst '\$SALT_USER' < /etc/salt/master.tmp | tee --append /etc/salt/master && \
rm /etc/salt/master.tmp
COPY ./docker/salt/supervisor.conf /etc/supervisor/conf.d/supervisor.conf
EXPOSE 8123 4505 4506
CMD ["/usr/bin/supervisord"]