mirror of
https://github.com/cwinfo/matterbridge.git
synced 2024-11-22 14:00:27 +00:00
ddc2625934
This change would be required for the Docker image to actually read `RELOADABLE` config options from the `matterbridge.toml`. This edit would require https://github.com/42wim/matterbridge/wiki/Deploy:-Docker to be updated as well to mention that mounting would have to change to mounting a ***directory*** not a file. inotify inside Docker cannot read directly mounted files, only directories, for whatever reason. This will preserve setups that were configured to run the old way without breaking them and new configs can be setup "correctly" without issue.
17 lines
677 B
Docker
17 lines
677 B
Docker
FROM alpine:edge AS builder
|
|
|
|
COPY . /go/src/github.com/42wim/matterbridge
|
|
RUN apk update && apk add go git gcc musl-dev \
|
|
&& cd /go/src/github.com/42wim/matterbridge \
|
|
&& export GOPATH=/go \
|
|
&& go get \
|
|
&& go build -x -ldflags "-X main.githash=$(git log --pretty=format:'%h' -n 1)" -o /bin/matterbridge
|
|
|
|
FROM alpine:edge
|
|
RUN apk --no-cache add ca-certificates mailcap
|
|
COPY --from=builder /bin/matterbridge /bin/matterbridge
|
|
RUN mkdir /etc/matterbridge
|
|
RUN touch /etc/matterbridge/matterbridge.toml
|
|
RUN ln -sf /matterbridge.toml /etc/matterbridge/matterbridge.toml
|
|
ENTRYPOINT ["/bin/matterbridge", "-conf", "/etc/matterbridge/matterbridge.toml"]
|