| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263 | 
							- from debian as build-rtl_433
 
- RUN apt-get update && apt-get upgrade -y 
 
- RUN apt-get install -y libtool libusb-1.0.0-dev librtlsdr-dev rtl-sdr build-essential autoconf cmake pkg-config git && apt-get clean
 
- RUN git clone https://github.com/merbanan/rtl_433.git
 
- WORKDIR /rtl_433
 
- RUN mkdir -p build
 
- WORKDIR /rtl_433/build
 
- RUN cmake -DCMAKE_INSTALL_PREFIX=/rtl_433/install ../
 
- RUN make -j $(nproc) install
 
- from debian as build-logger
 
- RUN apt-get update && apt-get upgrade -y
 
- #############################
 
- from golang as build-log
 
- RUN mkdir -p /go/src/git.snppla.net/snppla/log_temperature
 
- ADD ./ /go/src/git.snppla.net/snppla/log_temperature/
 
- WORKDIR /go/src/git.snppla.net/snppla/log_temperature/temperature_logger
 
- ENV GOPATH /go
 
- ENV GOBIN /go/bin
 
- RUN go get
 
- RUN go install
 
- WORKDIR /go/src/git.snppla.net/snppla/json_get/
 
- RUN go get
 
- RUN go install
 
- #############################
 
- from debian as json_get
 
- COPY --from=build-log /go/bin/json_get /usr/bin
 
- ENV DB temperature
 
- ENV USER ""
 
- ENV PASSWORD ""
 
- ENV HOST http://localhost:80
 
- ENV DB_HOST http://localhost:8086
 
- ENV LOCATION "unknown"
 
- ENV DELAY 60
 
- CMD json_get -db $DB -host $HOST -dbHost $DB_HOST -location $LOCATION -password $PASSWORD -user $USER -delay $DELAY
 
- ##############################
 
- from debian as log_temperature
 
- RUN apt-get update && apt-get upgrade -y 
 
- RUN apt-get install -y librtlsdr0 && apt-get clean
 
- COPY --from=build-rtl_433 /rtl_433/install/bin/rtl_433 /usr/bin
 
- COPY --from=build-log /go/bin/temperature_logger /usr/bin
 
- ENV DB temperature
 
- ENV USER ""
 
- ENV PASSWORD ""
 
- ENV HOST http://localhost:8086
 
- ENV RTL_ARGS ""
 
- ENV LOCATIONS ""
 
- CMD rtl_433 $RTL_ARGS -F json | temperature_logger -host $HOST -db $DB -password $PASSWORD -user $USER $LOCATIONS
 
- ##############################
 
 
  |