diff service/reasoning/makefile @ 351:7716b1810d6c

reasoning & collector move into docker images Ignore-this: 67e97d307eba96791cbe77e57c57ad57
author drewp@bigasterisk.com
date Mon, 03 Sep 2018 00:45:34 -0700
parents
children 2efa246a65e7
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/service/reasoning/makefile	Mon Sep 03 00:45:34 2018 -0700
@@ -0,0 +1,23 @@
+JOB=reasoning
+PORT=9071
+
+TAG=bang6:5000/${JOB}_x86:latest
+
+build_image:
+	rm -rf tmp_ctx
+	mkdir -p tmp_ctx
+	cp -a Dockerfile ../../lib/*.py ../../lib/twisted_sse_demo *.py *.n3 input req* tmp_ctx
+	rsync -a input tmp_ctx/
+	docker build --network=host -t ${TAG} tmp_ctx
+	docker push ${TAG}
+	rm -r tmp_ctx
+
+shell:
+	docker run --rm -it --cap-add SYS_PTRACE --net=host ${TAG}  /bin/bash
+
+local_run:
+	docker run --rm -it -p ${PORT}:${PORT} \
+          -v `pwd`:/mnt \
+          --net=host \
+          ${TAG} \
+          python /mnt/${JOB}.py -iro