From a60521420b294fba8c3c89e15e67477a2549749e Mon Sep 17 00:00:00 2001 From: Jakob Ketterl Date: Mon, 21 Jan 2019 17:02:58 +0000 Subject: [PATCH] prepare separate images based on the used sdr device --- build.sh | 4 +++- Dockerfile => docker/Dockerfiles/Dockerfile-base | 4 ++-- docker/Dockerfiles/Dockerfile-rtlsdr | 5 +++++ docker/Dockerfiles/Dockerfile-sdrplay | 5 +++++ docker/scripts/install-dependencies-rtlsdr.sh | 2 ++ docker/scripts/install-dependencies-sdrplay.sh | 2 ++ docker/{ => scripts}/install-dependencies.sh | 0 docker/{ => scripts}/install-lib.patch | 0 docker/{ => scripts}/run.sh | 0 push.sh | 2 +- 10 files changed, 20 insertions(+), 4 deletions(-) rename Dockerfile => docker/Dockerfiles/Dockerfile-base (55%) create mode 100644 docker/Dockerfiles/Dockerfile-rtlsdr create mode 100644 docker/Dockerfiles/Dockerfile-sdrplay create mode 100755 docker/scripts/install-dependencies-rtlsdr.sh create mode 100755 docker/scripts/install-dependencies-sdrplay.sh rename docker/{ => scripts}/install-dependencies.sh (100%) rename docker/{ => scripts}/install-lib.patch (100%) rename docker/{ => scripts}/run.sh (100%) diff --git a/build.sh b/build.sh index 1977aac..fdfb3c7 100755 --- a/build.sh +++ b/build.sh @@ -1,2 +1,4 @@ #!/bin/bash -docker build -t jketterl/openwebrx:latest . +docker build -t openwebrx-base -f docker/Dockerfiles/Dockerfile-base . +docker build -t jketterl/openwebrx-rtlsdr -t jketterl/openwebrx -f docker/Dockerfiles/Dockerfile-rtlsdr . +docker build -t jketterl/openwebrs-sdrplay -f docker/Dockerfiles/Dockerfile-sdrplay . diff --git a/Dockerfile b/docker/Dockerfiles/Dockerfile-base similarity index 55% rename from Dockerfile rename to docker/Dockerfiles/Dockerfile-base index c4ec602..54dfbdf 100644 --- a/Dockerfile +++ b/docker/Dockerfiles/Dockerfile-base @@ -1,6 +1,6 @@ FROM raspbian/stretch -ADD docker/install-dependencies.sh / +ADD docker/scripts/install-dependencies.sh / RUN /install-dependencies.sh ADD . /openwebrx @@ -9,5 +9,5 @@ WORKDIR /openwebrx VOLUME /config -ENTRYPOINT [ "/openwebrx/docker/run.sh" ] +ENTRYPOINT [ "/openwebrx/docker/scripts/run.sh" ] EXPOSE 8073 diff --git a/docker/Dockerfiles/Dockerfile-rtlsdr b/docker/Dockerfiles/Dockerfile-rtlsdr new file mode 100644 index 0000000..5daba32 --- /dev/null +++ b/docker/Dockerfiles/Dockerfile-rtlsdr @@ -0,0 +1,5 @@ +FROM openwebrx-base + +ADD docker/scripts/install-dependencies-rtlsdr.sh / +RUN /install-dependencies-rtlsdr.sh + diff --git a/docker/Dockerfiles/Dockerfile-sdrplay b/docker/Dockerfiles/Dockerfile-sdrplay new file mode 100644 index 0000000..c38f9d1 --- /dev/null +++ b/docker/Dockerfiles/Dockerfile-sdrplay @@ -0,0 +1,5 @@ +FROM openwebrx-base + +ADD docker/scripts/install-dependencies-sdrplay.sh / +RUN /install-dependencies-sdrplay.sh + diff --git a/docker/scripts/install-dependencies-rtlsdr.sh b/docker/scripts/install-dependencies-rtlsdr.sh new file mode 100755 index 0000000..13f4793 --- /dev/null +++ b/docker/scripts/install-dependencies-rtlsdr.sh @@ -0,0 +1,2 @@ +#!/bin/sh + diff --git a/docker/scripts/install-dependencies-sdrplay.sh b/docker/scripts/install-dependencies-sdrplay.sh new file mode 100755 index 0000000..05a7907 --- /dev/null +++ b/docker/scripts/install-dependencies-sdrplay.sh @@ -0,0 +1,2 @@ +#!/bin/bash + diff --git a/docker/install-dependencies.sh b/docker/scripts/install-dependencies.sh similarity index 100% rename from docker/install-dependencies.sh rename to docker/scripts/install-dependencies.sh diff --git a/docker/install-lib.patch b/docker/scripts/install-lib.patch similarity index 100% rename from docker/install-lib.patch rename to docker/scripts/install-lib.patch diff --git a/docker/run.sh b/docker/scripts/run.sh similarity index 100% rename from docker/run.sh rename to docker/scripts/run.sh diff --git a/push.sh b/push.sh index a2548af..6853b70 100755 --- a/push.sh +++ b/push.sh @@ -1,2 +1,2 @@ #!/bin/bash -docker push jketterl/openwebrx +docker push jketterl/openwebrx jketterl/openwebrx-rtlsdr jketterl/openwebrx-sdrplay