aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@gentoo.org>2020-06-19 11:36:00 -0700
committerRobin H. Johnson <robbat2@gentoo.org>2020-06-19 11:36:00 -0700
commitedadb49a8b4ccb5680dabaa9f5a7931ea90cea7c (patch)
tree997628063bbb109491ab7c63ea899bc76b3ad907 /bin/build.sh
parentbin/update-userinfo.sh: fix stub userinfo.json (diff)
downloadwww-edadb49a8b4ccb5680dabaa9f5a7931ea90cea7c.tar.gz
www-edadb49a8b4ccb5680dabaa9f5a7931ea90cea7c.tar.bz2
www-edadb49a8b4ccb5680dabaa9f5a7931ea90cea7c.zip
Prep for generation via Docker
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
Diffstat (limited to 'bin/build.sh')
-rw-r--r--bin/build.sh16
1 files changed, 16 insertions, 0 deletions
diff --git a/bin/build.sh b/bin/build.sh
new file mode 100644
index 0000000..618b26a
--- /dev/null
+++ b/bin/build.sh
@@ -0,0 +1,16 @@
+#!/bin/bash
+set -e
+IMAGE_NAME=docker.gentoo.org/sites/www
+IMAGE_TAG=latest
+IMAGE=${IMAGE_NAME}:${IMAGE_TAG}
+IMAGE_SRC=docker/
+docker build -t "${IMAGE}" "${IMAGE_SRC}"
+docker run \
+ --rm \
+ --net=none \
+ -e JEKYLL_UID=$(id -u) \
+ -e JEKYLL_GID=$(id -g) \
+ --volume="${PWD}:/srv/jekyll" \
+ --volume="${PWD}/.bundle:/usr/local/bundle/" \
+ "${IMAGE}" \
+ jekyll build