aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
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