treebird-docker/Dockerfile
icscarythings eaa2c093f6 allow FCGI to be connected to with -p port:port instead of using --network host set
change fcgi bind address to 0.0.0.0 so it can be accessed outside the container with -p port:port instead of using --network host
2022-05-22 09:27:34 -04:00

17 lines
No EOL
549 B
Docker

FROM debian:testing
# TODO: have build and run deps seperate so the container can be made more lean
ENV BUILD_REQ="build-essential libcurl4-gnutls-dev libcjson-dev libpcre3-dev libfcgi-dev git pkgconf"
ENV RUN_REQ="spawn-fcgi fcgiwrap"
RUN apt update && apt upgrade -y
RUN apt install -y $BUILD_REQ $RUN_REQ
ENV TB_BUILD_DIR=/usr/local/src/treebird
COPY treebird $TB_BUILD_DIR
RUN make -C $TB_BUILD_DIR && make -C $TB_BUILD_DIR install
ENV TB_EXEC_BIN=/usr/local/bin/treebird
RUN chmod a+x $TB_EXEC_BIN
CMD fcgiwrap -c 10 -f -s tcp:0.0.0.0:4008