Files
addons/mosquitto/Dockerfile
Pascal Vizeli 6af0f83c55 Mqtt update (#620)
* Update Mosquitto / Auth plugin

* file

* extract auth plugin builder

* fix arm

* fix build

* Fix multiarch build

* cleanup

* test

* Use own plugin

* cleanup config handling

* Fix startup

* revert bashio config

* fix error

* Update CHANGELOG.md

* cleanup
2019-07-01 15:37:53 +02:00

27 lines
778 B
Docker

ARG BUILD_FROM
FROM $BUILD_FROM
# Install mosquitto + auth plugin
WORKDIR /usr/src
ARG MOSQUITTO_AUTH_VERSION
RUN apk add --no-cache \
mosquitto curl openssl musl socat pwgen \
&& apk add --no-cache --virtual .build-dependencies \
build-base git mosquitto-dev curl-dev openssl-dev \
&& git clone --depth 1 -b ${MOSQUITTO_AUTH_VERSION} https://github.com/pvizeli/mosquitto-auth-plug \
&& cd mosquitto-auth-plug \
&& cp config.mk.in config.mk \
&& make \
&& mkdir -p /usr/share/mosquitto \
&& cp -f auth-plug.so /usr/share/mosquitto \
&& apk del .build-dependencies \
&& rm -fr /usr/src/mosquitto-auth-plug
# Copy data
COPY data/run.sh /
COPY data/auth_srv.sh /bin/
COPY data/mosquitto.conf /etc/
WORKDIR /
CMD [ "/run.sh" ]