From 6fcba2bc08ffb1fa4ad6a0b6950cdd83fa376e64 Mon Sep 17 00:00:00 2001 From: Philippe Teuwen Date: Sat, 4 Sep 2021 23:33:52 +0200 Subject: [PATCH] Add docker for new stable Debian --- docker/debian-bullseye/Dockerfile | 19 +++++++++++++++++++ docker/debian-bullseye/README.md | 9 +++++++++ docker/debian-bullseye/docker_build.sh | 3 +++ docker/debian-bullseye/docker_rm.sh | 4 ++++ docker/debian-bullseye/docker_run.sh | 3 +++ 5 files changed, 38 insertions(+) create mode 100644 docker/debian-bullseye/Dockerfile create mode 100644 docker/debian-bullseye/README.md create mode 100755 docker/debian-bullseye/docker_build.sh create mode 100644 docker/debian-bullseye/docker_rm.sh create mode 100755 docker/debian-bullseye/docker_run.sh diff --git a/docker/debian-bullseye/Dockerfile b/docker/debian-bullseye/Dockerfile new file mode 100644 index 000000000..7533377d3 --- /dev/null +++ b/docker/debian-bullseye/Dockerfile @@ -0,0 +1,19 @@ +FROM debian:bullseye-slim + +ENV LANG C +ENV DEBIAN_FRONTEND noninteractive +# qtbase5-dev skipped +RUN apt-get update && \ + apt-get dist-upgrade -y && \ + apt-get install -y --no-install-recommends git ca-certificates build-essential cmake pkg-config libreadline-dev gcc-arm-none-eabi libnewlib-dev libbz2-dev libbluetooth-dev sudo && \ + apt-get clean + +# Create rrg user +RUN useradd -ms /bin/bash rrg +RUN passwd -d rrg +RUN printf 'rrg ALL=(ALL) ALL\n' | tee -a /etc/sudoers + +USER rrg +WORKDIR "/home/rrg" + +CMD ["/bin/bash"] diff --git a/docker/debian-bullseye/README.md b/docker/debian-bullseye/README.md new file mode 100644 index 000000000..c6fce658c --- /dev/null +++ b/docker/debian-bullseye/README.md @@ -0,0 +1,9 @@ +# Notes to run tests + +``` +sudo apt update +sudo apt install python3-minimal +sudo apt install python3-pip +python3 -m pip install ansicolors sslcrypto +tools/pm3_tests.sh --long +``` diff --git a/docker/debian-bullseye/docker_build.sh b/docker/debian-bullseye/docker_build.sh new file mode 100755 index 000000000..3b44dd72c --- /dev/null +++ b/docker/debian-bullseye/docker_build.sh @@ -0,0 +1,3 @@ +#!/bin/bash + +docker build -t "pm3-debian-bullseye:1.0" . diff --git a/docker/debian-bullseye/docker_rm.sh b/docker/debian-bullseye/docker_rm.sh new file mode 100644 index 000000000..d9609e2dd --- /dev/null +++ b/docker/debian-bullseye/docker_rm.sh @@ -0,0 +1,4 @@ +#!/bin/bash + +docker image rm pm3-debian-bullseye:1.0 +docker image rm bullseye-slim diff --git a/docker/debian-bullseye/docker_run.sh b/docker/debian-bullseye/docker_run.sh new file mode 100755 index 000000000..abe9dce77 --- /dev/null +++ b/docker/debian-bullseye/docker_run.sh @@ -0,0 +1,3 @@ +#!/bin/bash + +docker run --volume=$(pwd)/../..:/home/rrg/proxmark3 -it pm3-debian-bullseye:1.0