diff options
Diffstat (limited to '')
-rw-r--r-- | Dockerfile | 9 | ||||
-rw-r--r-- | Makefile | 6 |
2 files changed, 15 insertions, 0 deletions
diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..17b087b --- /dev/null +++ b/Dockerfile @@ -0,0 +1,9 @@ +FROM haskell:8.8 +WORKDIR /opt/cafp +COPY server/cafp.cabal server/stack.yaml* /opt/cafp/ +RUN stack build --only-dependencies +COPY server /opt/cafp +RUN stack build +ENV CAFP_HOSTNAME=0.0.0.0 CAFP_PORT=8002 CAFP_BASE=/cafp +EXPOSE 8002 +CMD stack exec cafp-server @@ -3,6 +3,7 @@ include config.mk HS_SOURCES=$(shell find server/lib/ server/src -name '*.hs') ELM_SOURCES=$(shell find client/src -name '*.elm') ELM_MESSAGES_SOURCE=client/src/Messages.elm +STACK_BIN=$(shell cd server && stack path --local-install-root)/bin .PHONY: build build: server/assets/client.js \ @@ -11,6 +12,11 @@ build: server/assets/client.js \ server/assets/black.txt \ server/assets/white.txt +.PHONY: docker +docker: + docker build -t jaspervdj/cafp . + docker push jaspervdj/cafp + .PHONY: server server: build (cd server && \ |