summaryrefslogtreecommitdiff
blob: a55c19039177d2a1c391ea64891d6fe166773f81 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#!/bin/sh

TS=$(date --iso=sec -u |sed -r 's,.00:00$,,g' |tr -c -d '[0-9]')
IMAGE=gentoo/planet-pluto
TAG=latest

USER=${1:-gplanet}
GROUP=${2:-gplanet}

mkdir -p htdocs data
chown -R $USER:$GROUP htdocs data

docker run \
	--rm \
	--privileged \
	--restart no \
	--mount type=bind,source="$(pwd)"/htdocs,target=/var/www/planet.gentoo.org/build \
	--mount type=bind,source="$(pwd)"/data,target=/var/www/planet.gentoo.org/data \
	--name ${IMAGE}_${TS}
	${IMAGE}:${TAG}