more fixes

This commit is contained in:
Christoph Honal 2020-02-12 18:19:25 +01:00
parent 110f6adf09
commit 210019e2f9
7 changed files with 26 additions and 9 deletions

View File

@ -82,7 +82,8 @@ ENV PATH="/app/move2radio/build/prefix/usr/bin:${PATH}" \
# Install binaries # Install binaries
COPY build/blocks/* app/move2radio/build/prefix/usr/share/gnuradio/grc/blocks/ COPY build/blocks/* app/move2radio/build/prefix/usr/share/gnuradio/grc/blocks/
COPY build/fakeserver/* /app/fakeserver/ COPY build/fakeserver/* /app/fakeserver/
COPY build/run.sh /app/run.sh ARG UI_MODE=cli
COPY build/run-${UI_MODE}.sh /app/run.sh
RUN chmod 644 app/move2radio/build/prefix/usr/share/gnuradio/grc/blocks/*.xml && \ RUN chmod 644 app/move2radio/build/prefix/usr/share/gnuradio/grc/blocks/*.xml && \
chmod +x /app/run.sh && ldconfig chmod +x /app/run.sh && ldconfig

View File

@ -1,2 +1,5 @@
# move2docker # Move2Docker
MOVE-II decoder docker container MOVE-II decoder docker container
## Usage
Use the scripts from the `scripts` directory to control the docker containers.

7
build/run-cli.sh Normal file
View File

@ -0,0 +1,7 @@
#!/bin/bash
mkdir -p /app/data/output
touch /app/data/output/frames.txt
python3 /app/fakeserver/server.py &
bash

View File

@ -5,6 +5,7 @@ source ./config/config.sh
export PROP_SERVER_KEY=$(cat ./config/id_rsa) export PROP_SERVER_KEY=$(cat ./config/id_rsa)
export UI_MODE=$1 export UI_MODE=$1
docker build --build-arg UI_MODE \ docker build \
--build-arg PROP_SERVER --build-arg PROP_SERVER_USER --build-arg PROP_SERVER_KEY \ --build-arg UI_MODE --build-arg PROP_SERVER --build-arg PROP_SERVER_USER \
--build-arg PROP_DIR_SDR --build-arg PROP_DIR_DECODER -t registry.chrz.de:443/move2docker:$UI_MODE-$(arch) . --build-arg PROP_SERVER_KEY --build-arg PROP_DIR_SDR --build-arg PROP_DIR_DECODER \
-t registry.chrz.de:443/move2docker:$UI_MODE-$(arch) .

View File

@ -5,6 +5,8 @@ source ./config/config.sh
export PROP_SERVER_KEY=$(cat ./config/id_rsa) export PROP_SERVER_KEY=$(cat ./config/id_rsa)
export UI_MODE=$1 export UI_MODE=$1
docker buildx build --platform linux/amd64,linux/arm64,linux/arm/v7 --build-arg UI_MODE \ docker buildx build \
--build-arg PROP_SERVER --build-arg PROP_SERVER_USER --build-arg PROP_SERVER_KEY \ --platform linux/amd64,linux/arm64,linux/arm/v7 \
--build-arg PROP_DIR_SDR --build-arg PROP_DIR_DECODER -t move2docker:$UI_MODE-latest . --build-arg UI_MODE --build-arg PROP_SERVER --build-arg PROP_SERVER_USER \
--build-arg PROP_SERVER_KEY --build-arg PROP_DIR_SDR --build-arg PROP_DIR_DECODER \
-t move2docker:$UI_MODE-latest .

View File

@ -4,4 +4,7 @@ cd "${0%/*}/.."
source ./config/config.sh source ./config/config.sh
export UI_MODE=$1 export UI_MODE=$1
docker run -it --rm -v ./data:/app/data:rw --env DISPLAY=host.docker.internal:0.0 registry.chrz.de:443/move2docker:$UI_MODE-latest-$(arch) docker run -it --rm \
-v $(pwd)/data:/app/data:rw \
--env DISPLAY=host.docker.internal:0.0 \
registry.chrz.de:443/move2docker:$UI_MODE-$(arch)