#!/usr/bin/env sh
XILINX_TOOLS=/opt/Xilinx

docker run \
    -v "$HOME":"$HOME" \
    -v /etc/passwd:/etc/passwd:ro \
    -v /etc/shadow:/etc/shadow:ro \
    -v /etc/group:/etc/group:ro \
    -v ${XILINX_TOOLS}:${XILINX_TOOLS} \
    -v /tmp/.X11-unix:/tmp/.X11-unix \
    -v /tmp:/tmp \
    -e DISPLAY=$DISPLAY \
    --privileged \
    --net=host \
    -i -w "$PWD" -u $(id -u):$(id -g) -t --rm \
    vivado bash
