22 lines
547 B
Bash
22 lines
547 B
Bash
|
#!/usr/bin/env bash
|
||
|
|
||
|
# Check if script exists that will run in the container
|
||
|
if [ ! -f scripts/compile_tmate.sh ]
|
||
|
then
|
||
|
echo "Script scripts/compile_tmate.sh not found!"
|
||
|
exit 1
|
||
|
fi
|
||
|
|
||
|
# Make sure that the script is executable
|
||
|
chmod u+x scripts/compile_tmate.sh
|
||
|
|
||
|
# Make sure that the "output directory" exists
|
||
|
mkdir -p bin
|
||
|
|
||
|
# Run container
|
||
|
podman run -it --rm --tz local -v ./scripts:/volumes/scripts:Z,ro -v ./bin:/volumes/bin:Z ubuntu:latest /volumes/scripts/compile_tmate.sh
|
||
|
|
||
|
echo "DONE!"
|
||
|
|
||
|
echo "The output binary can be found at bin/tmate"
|