Skip to content

Commit

Permalink
Merge pull request #288 from OpenSprinkler/support/https
Browse files Browse the repository at this point in the history
Support HTTPs
  • Loading branch information
rayshobby authored Jul 25, 2024
2 parents 9282327 + 3ab6cde commit d78964b
Show file tree
Hide file tree
Showing 27 changed files with 14,923 additions and 390 deletions.
7,873 changes: 7,873 additions & 0 deletions ArduinoJson.hpp

Large diffs are not rendered by default.

28 changes: 20 additions & 8 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,31 +1,43 @@
FROM debian:bookworm-slim AS base

ARG BUILD_VERSION="OSPI"

########################################
## 1st stage compiles OpenSprinkler runtime dependency raspi-gpio
FROM base AS raspi-gpio-build

ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y git gcc make automake && rm -rf /var/lib/apt/lists/*
RUN mkdir /raspi-gpio && cd /raspi-gpio && git clone --depth 1 https://github.com/RPi-Distro/raspi-gpio.git . && autoreconf -f -i && (./configure || cat config.log) && make
RUN apt-get update
RUN apt-get install -y git gcc make automake
RUN rm -rf /var/lib/apt/lists/*
RUN mkdir /raspi-gpio
WORKDIR /raspi-gpio
RUN git clone --depth 1 https://github.com/RPi-Distro/raspi-gpio.git .
RUN autoreconf -f -i
RUN (./configure || cat config.log)
RUN make

########################################
## 2nd stage compiles OpenSprinkler code
FROM base AS os-build

ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y bash g++ make libmosquittopp-dev libssl-dev && rm -rf /var/lib/apt/lists/*
RUN apt-get update && apt-get install -y bash g++ make libmosquittopp-dev libssl-dev
RUN rm -rf /var/lib/apt/lists/*
COPY . /OpenSprinkler
RUN cd /OpenSprinkler && make
WORKDIR /OpenSprinkler
RUN make clean
RUN make VERSION=${BUILD_VERSION}

########################################
## 3rd stage is minimal runtime + executable
FROM base

ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y libstdc++6 libmosquittopp1 && rm -rf /var/lib/apt/lists/* \
&& \
mkdir /OpenSprinkler && \
mkdir -p /data/logs
RUN apt-get update && apt-get install -y libstdc++6 libmosquittopp1
RUN rm -rf /var/lib/apt/lists/*
RUN mkdir /OpenSprinkler
RUN mkdir -p /data/logs

COPY --from=os-build /OpenSprinkler/OpenSprinkler /OpenSprinkler/OpenSprinkler
COPY --from=raspi-gpio-build /raspi-gpio/raspi-gpio /usr/bin/raspi-gpio
Expand Down
Loading

0 comments on commit d78964b

Please sign in to comment.