Docker: fix test for pm3 when building images
[RRG-proxmark3.git] / docker / ubuntu-20.04 / docker_run.sh
blobfe28c846d425afdf3177b03871343508ac0cb375
1 #!/bin/bash
3 . docker_conf
4 UART_PORT="$(../../pm3 --list|grep dev|head -n1|cut -d' ' -f2)"
5 if [ -n "$UART_PORT" ]; then
6 DEV="--device=/dev/tty0 --device=$UART_PORT"
7 else
8 DEV=""
9 fi
10 docker run $DEV --volume="$(pwd)/../..:/home/rrg/proxmark3" -w /home/rrg/proxmark3 -it "$DOCKER_IMAGE"