diff --git a/src/www.forecastbench.org/Makefile b/src/www.forecastbench.org/Makefile index 384b3e1..8bbe6ef 100644 --- a/src/www.forecastbench.org/Makefile +++ b/src/www.forecastbench.org/Makefile @@ -2,7 +2,7 @@ all : $(MAKE) clean $(MAKE) deploy -.PHONY : all clean deploy +.PHONY : all clean deploy dev-build dev-serve UPLOAD_DIR = upload @@ -67,3 +67,15 @@ deploy : entrypoint.sh Dockerfile .gcloudignore clean : rm -rf $(UPLOAD_DIR) .gcloudignore entrypoint.sh _site + +LOCAL_DOCKER_IMAGE_TAG = forecastbench-website + +dev-build : Dockerfile + docker build -t $(LOCAL_DOCKER_IMAGE_TAG) . + +dev-serve : dev-build + docker run --rm -it -p 4000:4000 \ + -v "$$(pwd):/srv/jekyll" \ + -w /srv/jekyll --entrypoint "" \ + $(LOCAL_DOCKER_IMAGE_TAG) \ + bundle exec jekyll serve --host 0.0.0.0 --config _config.yml --livereload \ No newline at end of file