feat: added helper dev container build script

pull/245/head^2
Josh Moore 7 months ago
parent da8494c511
commit 21f9bef6b2
No known key found for this signature in database
GPG Key ID: D448BA776D2B1D45

@ -0,0 +1,29 @@
#!/bin/bash
denv=FORCE_COLOR=3
volume=$(pwd)/.ass-data:/opt/ass-src/.ass-data
workdir=/opt/ass-src/
port=40115:40115
# container name:tag (tag is unix timestamp)
cname=ass:$(date +%s)
# build image
docker buildx build -t $cname .
# run the new image
docker run -it -e $denv -v $volume -w $workdir -p $port $cname
# wait for exit
echo
echo
echo -e "\033[32m\033[1mTo use this image again, run:\033[0m"
echo
echo " docker run -it \\"
echo " -e $denv \\"
echo " -v \$(pwd)/.ass-data:/opt/ass-src/.ass-data \\"
echo " -w $workdir \\"
echo " -p $port \\"
echo " $cname"
echo
Loading…
Cancel
Save