#!/usr/bin/env bash
# Build the image (needs network once), then run the whole lab with networking OFF.
set -euo pipefail
cd "$(dirname "$0")"
docker build -q -t pb-lab . >/dev/null
rm -rf work && mkdir work
cp result.json lab.sh *.py work/
docker run --rm --network none -v "$PWD/work:/lab" pb-lab bash lab.sh 2>&1 | tee lab-output.txt
