├── .github └── dependabot.yml ├── .gitignore ├── LICENSE ├── README.md ├── bash_aliases ├── docker-install.sh ├── sample-docker-compose.yml └── sample-dot-env /.github/dependabot.yml: -------------------------------------------------------------------------------- 1 | version: 2 2 | 3 | updates: 4 | # Maintain dependencies for Docker 5 | - package-ecosystem: "docker" 6 | directory: "/" 7 | schedule: 8 | interval: "weekly" 9 | day: "saturday" 10 | time: "00:00" 11 | timezone: "Etc/UTC" 12 | assignees: 13 | - "fredclausen" 14 | 15 | # Maintain dependencies for GitHub Actions 16 | - package-ecosystem: "github-actions" 17 | directory: "/" 18 | schedule: 19 | interval: "weekly" 20 | day: "saturday" 21 | time: "00:00" 22 | timezone: "Etc/UTC" 23 | assignees: 24 | - "fredclausen" 25 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2022 Ramon F. Kolb (k1xt) 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # docker-install 2 | 3 | Script to help install Docker on Raspberry Pi and devices with similar Debian-based OSes 4 | 5 | 6 | 7 | - [docker-install](#docker-install) 8 | - [What is it?](#what-is-it) 9 | - [How to run it?](#how-to-run-it) 10 | - [Command Line Options](#command-line-options) 11 | - [Troubleshooting](#troubleshooting) 12 | - [Sample `docker-compose` configurations](#sample-docker-compose-configurations) 13 | - [Errors and how to deal with them](#errors-and-how-to-deal-with-them) 14 | - [License](#license) 15 | 16 | ## What is it? 17 | 18 | The [docker-install.sh](docker-install.sh) script helps users get ready to use the [SDR-Enthusiasts](https://github.com/sdr-enthusiasts)' (@mikenye/@fredclausen/@k1xt) Docker containers. 19 | The script is written to be used on a Debian (Ubuntu, DietPi, or Raspberry Pi OS) system that is "barebones", i.e., where Docker has not yet been installed. Debian OS versions Buster (Debian 10), Bullseye (Debian 11), and Bookworm (Debian 12) are supported. Debian OS Stretch (Debian 9) is no longer officially supported. The script should install successfully, but we are not providing any support for issues that occur on Debian Stretch. 20 | 21 | Note that this script will work across a number of Debian-based Linux Operating Systems, but the SDR-Enthusiast container only work on these hardware architectures: `armhf` (32-bit ARM CPUs with hardware floating point processor), `arm64` (64-bit ARM CPUs with hardware floating point processor), and `amd64` (64-bit Intel CPUs). 22 | 23 | We don't have sdr-enthusiasts containers available for any other architectures, including but not limited to `armel` (32-bit ARM CPUs with software floating point solution - some of the older Pi-Zero/Pi-1/Pi2 devices), `i386` (32 bits Intel CPUs), and `darwin` (MacOS devices). 24 | 25 | It will **check**, and if necessary **install** the following components and settings: 26 | 27 | - `docker` 28 | - install Docker 29 | - (optional) add the current user to the `sudoers` group and enable password-free use of `sudo` 30 | - configure log limits for Docker 31 | - configure $PATH environment for Docker 32 | - add current user to `docker` group 33 | - `docker-compose` 34 | - Install latest stable `docker-compose` from Github (and not the older version from the Debian Repo) 35 | - It will install a number of "helper" apps that are needed or recommended to use with the SDR-Enthusiasts containers 36 | - On Stretch/Buster/Bullseye OS versions, it will make sure that `libseccomp2` is of a new enough version to support Bullseye-based Docker containers 37 | - Update `udev` rules for use with RTL-SDR dongles 38 | - Exclude and uninstall SDR drivers so the `SDR-Enthusiasts`' ADSB and ACARS containers can access the RTL-SDR dongles. Unload any preloaded drivers. 39 | - on `dhcpd` based systems, exclude Docker Container-based virtual ethernet interfaces from using DHCP 40 | 41 | After running this script, your system should be ready to use `docker` and `docker-compose`, and you can start adding a `docker-compose.yml` file as described in Mike Nye's ADSB Gitbook. 42 | 43 | ## How to run it? 44 | 45 | - Feel free to inspect the script [here](docker-install.sh). You should really not blindly run other people's script - make sure you feel comfortable with what it does before executing it. 46 | - The script assumes that `wget` is available, as it is on most systems. If it isn't, you may have to install it before running the script with `sudo apt update && sudo apt install -y wget` 47 | - To use it, you can enter the following command in your login session: 48 | 49 | ```bash 50 | bash <(wget -q -O - https://raw.githubusercontent.com/sdr-enthusiasts/docker-install/main/docker-install.sh) 51 | ``` 52 | 53 | ## Command Line Options 54 | 55 | The script will install a number of packages, some of which are mandatory while others are optional. You can find the packages that will be installed [here](https://github.com/sdr-enthusiasts/docker-install/blob/main/docker-install.sh#L22). 56 | 57 | If you want to exclude certain packages from being installed, you can do so by adding them to the command line with the prefix `no-`. For example to exclude `chrony` from being installed, you would use `no-chrony`. 58 | 59 | In order to use command line options, it's easiest to download the script first, and then execute it from the command line like in this example: 60 | 61 | ```bash 62 | wget -q https://raw.githubusercontent.com/sdr-enthusiasts/docker-install/main/docker-install.sh 63 | chmod +x docker-install.sh 64 | ./docker-install.sh no-chrony 65 | rm -f ./docker-install.sh 66 | ``` 67 | 68 | ## Troubleshooting 69 | 70 | This script is a work of love, and the authors don't provide support for alternative platforms or configurations. 71 | Feel free to reuse those parts of the script that fit your purpose, subject to the License grant provided below. 72 | If you need help or find a bug, please raise an Issue. 73 | If you have improvements that you'd like to contribute, please raise a PR. 74 | 75 | ## Sample `docker-compose` configurations 76 | 77 | This repository also includes 2 sample docker configuration files for use with `docker compose` that contain service definitions for most of the SDR-Enthusiasts containers. These files should not be used as-is, but are good examples that the user can copy and paste from when creating their own `docker-compose.yml`. 78 | The sample configuration assumes that the `docker-compose.yml` file will be located in `/opt/adsb`. If you put your `docker-compose.yml` file in a different directory, you may have to update some of the volume mappings. 79 | 80 | - [`docker-compose.yml`](sample-docker-compose.yml) sample 81 | - [`.env`](sample-dot-env) sample 82 | 83 | ## Errors and how to deal with them 84 | 85 | - ISSUE: The script fails with the message below: 86 | 87 | ```text 88 | E: Repository 'http://raspbian.raspberrypi.org/raspbian buster InRelease' changed its 'Suite' value from 'stable' to 'oldstable' 89 | E: Repository 'http://archive.raspberrypi.org/debian buster InRelease' changed its 'Suite' value from 'testing' to 'oldstable' 90 | ``` 91 | 92 | - SOLUTION: First run `sudo apt-get update --allow-releaseinfo-change && sudo apt-get upgrade -y` and then run the install script again. 93 | - ISSUE: The "Hello World" docker test fails when executing the script. 94 | - SOLUTION: Ignore this for now -- it will probably work once the system has been rebooted after completing the installation 95 | 96 | ## License 97 | 98 | This software is licensed under the MIT License. The terms and conditions thereof can be found [here](LICENSE). 99 | -------------------------------------------------------------------------------- /bash_aliases: -------------------------------------------------------------------------------- 1 | alias ddown='docker compose down' 2 | alias dir='ls -alsvh --color=auto' 3 | alias dlogs='docker logs -n 100 -f' 4 | alias docker-compose='docker compose' 5 | alias dup='docker compose pull && docker compose up -d --remove-orphans && docker system prune -af --filter "label!=do_not_prune"' 6 | alias nano='nano -l' 7 | alias tb='nc termbin.com 9999' 8 | alias usboff='grep "Raspberry Pi 4" /sys/firmware/devicetree/base/model >/dev/null 2>&1 && sudo uhubctl -a off -l 1-1 || echo "Sorry, this is only available on Raspberry Pi 4"' 9 | alias usbon='grep "Raspberry Pi 4" /sys/firmware/devicetree/base/model >/dev/null 2>&1 && sudo uhubctl -a on -l 1-1 || echo "Sorry, this is only available on Raspberry Pi 4"' 10 | alias usbstatus='grep "Raspberry Pi 4" /sys/firmware/devicetree/base/model >/dev/null 2>&1 && sudo uhubctl || echo "Sorry, this is only available on Raspberry Pi 4"' 11 | alias usbtoggle='grep "Raspberry Pi 4" /sys/firmware/devicetree/base/model >/dev/null 2>&1 && sudo uhubctl -a toggle -l 1-1 || echo "Sorry, this is only available on Raspberry Pi 4"' 12 | alias dive="docker run -ti --rm -v /var/run/docker.sock:/var/run/docker.sock wagoodman/dive" 13 | 14 | export DOCKER_HOST="unix:///var/run/docker.sock" 15 | 16 | function dexec () { 17 | # shortcut for "docker exec it container bash ..." 18 | [[ -z "$1" ]] && { echo "Usage: dexec [commands]"; return 99; } || true 19 | docker ps | grep "Up" >/dev/null 2>&1 || { echo "No containers are running."; return 1; } 20 | docker exec -it $1 bash ${@:2} 21 | } 22 | 23 | function dhealth () { 24 | # shows the HealthCheck status for a container 25 | [[ -z "$1" ]] && { echo "Usage: dhealth "; return 99; } || true 26 | docker ps | grep "Up" >/dev/null 2>&1 || { echo "No containers are running."; return 1; } 27 | docker inspect --format "{{json .State.Health }}" $1 | jq '.Log[].Output' 28 | } 29 | 30 | function rtl_eeprom () { 31 | # this function is dockerized because the default Debian distro of rtl_sdr doesn't support some of the modern SDRs, e.g. RTLSDRv4 32 | docker run --label do_not_prune -it --device=/dev/bus/usb ghcr.io/sdr-enthusiasts/docker-baseimage:rtlsdr rtl_eeprom $@ |grep -v s6-rc 33 | } 34 | 35 | function rtl_test () { 36 | # this function is dockerized because the default Debian distro of rtl_sdr doesn't support some of the modern SDRs, e.g. RTLSDRv4 37 | docker run --label do_not_prune -it --device=/dev/bus/usb ghcr.io/sdr-enthusiasts/docker-baseimage:rtlsdr rtl_test $@ |grep -v s6-rc 38 | } 39 | 40 | function dip() { 41 | # this function shows the internal IP addresses and virtual ethernet interfaces that are created for each container 42 | docker ps | grep "Up" >/dev/null 2>&1 || { echo "No containers are running."; return 1; } 43 | readarray containers <<< "$(docker ps -q)" 44 | for c in ${containers[@]}; do 45 | veth="$(grep '^'"$(docker exec -it $c cat /sys/class/net/eth0/iflink | tr -d '\r')"'$' /sys/class/net/veth*/ifindex | awk -F'/' '{print $5}')" 46 | name="$(docker inspect --format '{{ .Name}}' $c)" 47 | ipaddress="$(docker inspect $c |sed -n 's|\s*"IPAddress": "\([0-9]\+\.[0-9]\+\.[0-9]\+\.[0-9]\+\).*|\1|p' | tail -1)" 48 | if [[ -z "$1" ]] || [[ "${name//\//}" == "$1" ]]; then 49 | echo "${name//\//} ${ipaddress:-no_ipadress_found} ${veth:-no_interface_found}" 50 | if [[ -n "$1" ]]; then break; fi 51 | fi 52 | done 53 | } 54 | 55 | function transfer() { 56 | # from transfer.sh -- use this function to easily transfer and retrieves files in the cloud 57 | # file size is up to 10 Gb are stored for 14 days 58 | # The output of this function is a URL that can be used to retrieve the file with `wget` or `curl` 59 | if [ $# -eq 0 ]; then 60 | printf "No arguments specified.\nUsage:\nUploading files: transfer \nDownloading files: transfer https://transfer.sh/filename [dest_filename]\n" >&2 61 | return 1 62 | fi 63 | file="$1" 64 | file_name=$(basename "$file") 65 | if [[ "${file:0:4}" == "http" ]]; then 66 | # transfer the file back to us 67 | if [[ -z "$2" ]]; then dest="$file_name"; else dest="$2"; fi 68 | if [[ -e "$dest" ]]; then 69 | printf "Error - destination file \"%s\" already exists. Please remove that file first, or use \"transfer https://transfer.sh/filename new_filename\"\n" "$dest" 70 | return 1 71 | fi 72 | curl --progress-bar "$file" > "$dest" 73 | if [[ "${dest##*.}" == "tgz" ]]; then 74 | echo "You can unpack this file tree with \"tar xvf $dest\" or \"tar xvf $dest -C /target/directory\"" 75 | fi 76 | return 0 77 | fi 78 | if [ ! -e "$file" ]; then 79 | echo "$file: No such file or directory" >&2 80 | return 1 81 | fi 82 | if [ -d "$file" ]; then 83 | file_name="$file_name.tgz" 84 | tempfile=$(mktemp --suffix=.tgz) 85 | echo -n "Compressing directory $file... " 86 | tar zcf "$tempfile" "$file" 87 | echo "Uploading to transfer.sh..." 88 | curl --progress-bar --upload-file "$tempfile" "https://transfer.sh/$file_name" 89 | rm -f "$tempfile" 90 | else 91 | curl --progress-bar --upload-file "$file" "https://transfer.sh/$file_name" 92 | fi 93 | echo 94 | } 95 | 96 | function dupall() { for d in /opt/*; do if [[ -f "$d/docker-compose.yml" ]]; then pushd "$d"; dup; popd; fi; done; } 97 | -------------------------------------------------------------------------------- /docker-install.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | #shellcheck shell=bash external-sources=false disable=SC1090,SC2015,SC2164,SC2128,SC2076 3 | # DOCKER-INSTALL.SH -- Installation script for the Docker infrastructure on a Raspbian or Ubuntu system 4 | # Usage: source <(curl -s https://raw.githubusercontent.com/sdr-enthusiasts/docker-install/main/docker-install.sh) 5 | # 6 | # Copyright 2021-2024 Ramon F. Kolb (kx1t) 7 | # 8 | # Licensed under the terms and conditions of the MIT license. 9 | # https://github.com/sdr-enthusiasts/docker-install/main/LICENSE 10 | # 11 | trap 'echo "[ERROR] Error in line $LINENO when executing: $BASH_COMMAND"' ERR 12 | # ------------------------------------------------------------------------------------------ 13 | # VARIABLE DEFINITIONS: 14 | # These are the supported architectures for SDR-enthusiasts docker containers 15 | # We will warn if the system reports a different architecture 16 | # 17 | # 28-Mar-2024 - note, in the future, we are considering removing armhf as supported architecture for the installation 18 | # because several of our containers no longer work on this architecture. 19 | SUPPORTED_ARCH=(armhf) 20 | SUPPORTED_ARCH+=(arm64) 21 | SUPPORTED_ARCH+=(aarch64) 22 | SUPPORTED_ARCH+=(amd64) 23 | SUPPORTED_ARCH+=(x86_64) 24 | 25 | # 26 | # This is the list of applications that we want to have installed to ensure good working 27 | # of the containerized SDR environment: 28 | APT_INSTALLS=(apt-transport-https) 29 | APT_INSTALLS+=(ca-certificates) 30 | APT_INSTALLS+=(curl) 31 | APT_INSTALLS+=(gnupg2) 32 | APT_INSTALLS+=(slirp4netns) 33 | APT_INSTALLS+=(software-properties-common) 34 | APT_INSTALLS+=(uidmap) 35 | APT_INSTALLS+=(w3m) 36 | APT_INSTALLS+=(jq) 37 | APT_INSTALLS+=(git) 38 | APT_INSTALLS+=(rtl-sdr) 39 | APT_INSTALLS+=(chrony) 40 | if grep "Raspberry Pi 4" /sys/firmware/devicetree/base/model >/dev/null 2>&1; then APT_INSTALLS+=(uhubctl); fi 41 | if ! grep "bookworm" /etc/os-release >/dev/null 2>&1; then APT_INSTALLS+=(netcat); else APT_INSTALLS+=(netcat-openbsd); fi 42 | # 43 | # This is the list of SDR modules/drivers that need to get excluded 44 | # Please keep the list in this order and add any additional ones to the BOTTOM 45 | BLOCKED_MODULES=("rtl2832_sdr") 46 | BLOCKED_MODULES+=("dvb_usb_rtl2832u") 47 | BLOCKED_MODULES+=("dvb_usb_rtl28xxu") 48 | BLOCKED_MODULES+=("dvb_usb_v2") 49 | BLOCKED_MODULES+=("r820t") 50 | BLOCKED_MODULES+=("rtl2830") 51 | BLOCKED_MODULES+=("rtl2832") 52 | BLOCKED_MODULES+=("rtl2838") 53 | BLOCKED_MODULES+=("dvb_core") 54 | # 55 | # Recommended Debian version: 56 | RECOMMENDED_DEBIAN=("12 (bookworm)") # standard Debian version name. This is the one that will show as recommended 57 | RECOMMENDED_DEBIAN+=("22.04") # Ubuntu current LTS release 58 | RECOMMENDED_DEBIAN+=("23.04") # Ubuntu current normal release 59 | RECOMMENDED_DEBIAN+=("23.10") # Ubuntu current normal release 60 | # 61 | # ------------------------------------------------------------------------------------------ 62 | 63 | clear 64 | cat << "EOM" 65 | __/\__ 66 | `==/\==` ____ _ ___ _ _ _ 67 | ____________/__\____________ | _ \ ___ ___| | _____ _ __ |_ _|_ __ ___| |_ __ _| | | 68 | /____________________________\ | | | |/ _ \ / __| |/ / _ \ '__| | || '_ \/ __| __/ _` | | | 69 | __||__||__/.--.\__||__||__ | |_| | (_) | (__| < __/ | | || | | \__ \ || (_| | | | 70 | /__|___|___( >< )___|___|__\ |____/ \___/ \___|_|\_\___|_| |___|_| |_|___/\__\__,_|_|_| 71 | _/`--`\_ 72 | jgs (/------\) 73 | 74 | Welcome to the Docker Infrastructure installation script. We will help you install Docker and Docker-compose 75 | and then help you with your configuration. 76 | 77 | This script is Copyright 2021-2024 Ramon F. Kolb (kx1t) and other contributors. It is maintained by the SDR-Enthusiasts Organization. 78 | It is licensed under the terms and conditions of the MIT license. 79 | https://github.com/sdr-enthusiasts/docker-install/main/LICENSE 80 | 81 | Join us at https://discord.com/invite/mBRTWnjS3M where we can provide help and further support. 82 | 83 | EOM 84 | 85 | if ! which jq >/dev/null 2>&1 || ! which curl >/dev/null 2>&1; then 86 | echo "One moment while we install the minimally needed software (curl and jq) for the script to run. This will take 15-30 seconds (or longer on systems with very slow internet)" 87 | sudo bash -c "apt -qq update >/dev/null 2>&1 && apt -qq -y install curl jq >/dev/null 2>&1" 88 | fi 89 | 90 | echo "The script was last updated on $(date -d "$(curl -sSL -X GET -H "Cache-Control: no-cache" https://api.github.com/repos/sdr-enthusiasts/docker-install/commits??path=docker-install.sh | jq -r '.[0].commit.committer.date')")" 91 | cat << "EOM" 92 | 93 | Note - this script makes use of "sudo" to install Docker. 94 | If you haven't added your current login to the "sudoer" list, 95 | you may be asked for your password at various times during the installation. 96 | EOM 97 | 98 | if [[ "$EUID" == 0 ]]; then 99 | echo 100 | echo "STOP -- you are running this script using an account with superuser privileges (i.e., $USER). It is best practice to NOT install Docker services as \"$USER\" user." 101 | echo "Instead please log out from this account, log in as a different non-superuser account, and rerun this script." 102 | echo "If you are unsure of how to create a new user, you can learn how here: https://linuxize.com/post/how-to-create-a-sudo-user-on-debian/" 103 | echo 104 | exit 1 105 | fi 106 | 107 | os_recommended=false 108 | if [[ -f /etc/os-release ]]; then 109 | for os in "${RECOMMENDED_DEBIAN[@]}"; do 110 | #shellcheck disable=SC2143 111 | if grep -q "$os" /etc/os-release; then 112 | os_recommended=true 113 | break 114 | fi 115 | done 116 | fi 117 | 118 | if [[ "$os_recommended" == false ]]; then 119 | echo 120 | echo "WARNING: This device isn't running the newest recommended version of the Debian Linux OS." 121 | if grep -q "stretch" /etc/os-release; then 122 | echo "This device appears to be running Debian 9 (\"Stretch\"), which has been End of Life (EOL) since June 2022 and is no longer actively supported by the community." 123 | echo "If you encounter issues, consider upgrading to Debian 11 (\"Bullseye\") or 12 (\"Bookworm\")." 124 | echo 125 | echo "We can try to install Docker anyway, but if you come across any issues, we unfortunately are unable to support you." 126 | echo "In that case, please upgrade your OS to Debian ${RECOMMENDED_DEBIAN[0]}." 127 | elif [[ -f /etc/os-release ]]; then 128 | echo "This device appears to be running Debian $(sed -n 's/^VERSION=\"\(.*\)\"$/\1/p' /etc/os-release 2>/dev/null). Although installation will probably work, we recommend upgrading your OS to Debian $RECOMMENDED_DEBIAN if possible." 129 | elif [[ -n "$MACHTYPE" ]]; then 130 | echo "This device appears to be running a non-Debian OS identified by $MACHTYPE. This script only works on DEBIAN operating systems as it uses Debian specific commands like \"apt\" and \"dpkg\"." 131 | echo "Aborting!" 132 | exit 99 133 | else 134 | echo "This device appears to be running an unknown OS. This script relies on specific Debian commands commands like \"apt\" and \"dpkg\"." 135 | echo "As a result, the script will probably fail. You can try to continue, but we are unable to support you if any errors occur." 136 | echo "In that case, please upgrade your OS to Debian ${RECOMMENDED_DEBIAN[0]}, using for example to the latest version of DietPi, Raspberry Pi OS, Armbian, or Ubuntu." 137 | fi 138 | echo "" 139 | echo "This script strongly prefers a \"standard\" OS setup of Debian Buster/Bullseye/Bookworm, including variations like" 140 | echo "Raspberry Pi OS, DietPi, Armbian, or Ubuntu. It uses 'apt-get', 'dpkg', and 'wget' to get started," 141 | echo "and assumes access to the standard package repositories." 142 | echo "" 143 | echo "If you are starting with a newly installed Linux build, we strongly suggest you to use" 144 | echo "the latest version of Debian (currently Debian ${RECOMMENDED_DEBIAN[0]})." 145 | fi 146 | 147 | # check if the current architecture is supported 148 | #shellcheck disable=SC2076 149 | 150 | ARCH="$(dpkg --print-architecture 2>/dev/null || echo "${MACHTYPE%%*-}")" 151 | if [[ "$ARCH" == "arm" ]] && [[ "${MACHTYPE: -9}" == "gnueabihf" ]]; then ARCH="armhf"; fi 152 | ARCH="${ARCH:-unknown}" 153 | 154 | if [[ ! " ${SUPPORTED_ARCH[*]} " =~ " $ARCH " ]]; then 155 | echo 156 | echo "WARNING: Your system reports \"$ARCH\" as architecture." 157 | echo " This is not supported by most of the SDR-Enthusiasts SDR-related containers." 158 | echo " These only support the following architectures: ${SUPPORTED_ARCH[*]}." 159 | echo " You can continue to use this script, but please note that you can't use this system with any of the SDR-Enthusiasts containers." 160 | echo 161 | echo -n "Press CTRL-C to abort. " 162 | fi 163 | 164 | if [[ "$ARCH" == "armhf" ]]; then 165 | echo 166 | echo "WARNING: Your system reports \"$ARCH\" as architecture." 167 | echo " We will discontinue support for 32-bits ARM Linux in the near future. We strongly suggest you upgrade your machine, if possible," 168 | echo " to a 64-bit Debian Linux OS, such as DietPi, Ubuntu, or Raspberry Pi OS (64 bits)." 169 | echo " You can continue to use this script, but please note that some of the SDR-Enthusiasts containers already no longer support $ARCH." 170 | echo 171 | echo -n "Press CTRL-C to abort. " 172 | fi 173 | 174 | # Before installing the files, remove the ones in the command line that have been marked with "no-xxx" 175 | # For example, set "no-chrony" to omit Chrony from being installed. 176 | 177 | #shellcheck disable=SC2199 178 | if [[ -n "$@" ]]; then 179 | readarray -d ' ' -t argv <<< "$@" 180 | echo -n "The following applications will be excluded from the installation: " 181 | for i in "${argv[@]}"; do 182 | i="${i,,}" # make lowercase 183 | i="${i//[$'\t\r\n ']}" # strip any newlines, spaces, etc. 184 | if [[ "${i:0:3}" == "no-" ]]; then 185 | for j in "${!APT_INSTALLS[@]}"; do 186 | if [[ "${i:3}" == "${APT_INSTALLS[j]}" ]]; then 187 | echo -n "${APT_INSTALLS[j]} " 188 | unset "APT_INSTALLS[j]" 189 | fi 190 | done 191 | fi 192 | done 193 | echo 194 | fi 195 | 196 | read -r -p "Press ENTER to start." 197 | 198 | echo -n "First we will update your system and install some dependencies ... " 199 | sudo apt-get update -q -y >/dev/null 200 | sudo apt-get upgrade -q -y 201 | sudo apt-get install -q -y "${APT_INSTALLS[@]}" >/dev/null 202 | 203 | if ! grep sudo /etc/group | grep -qe ":${USER}$"; then 204 | echo "We'll start by adding your login name, \"${USER}\", to \"sudoers\". This will enable you to use \"sudo\" without having to type your password every time." 205 | echo "You may be asked to enter your password a few times below. We promise, this is the last time." 206 | echo 207 | read -r -p "Should we do this now? If you choose \"no\", you can always to it later by yourself [Y/n] > " -n 1 text 208 | if [[ "${text,,}" != "n" ]] 209 | then 210 | echo 211 | echo -n "Adding user \"${USER}\" to the 'sudo' group... " 212 | sudo usermod -aG sudo "${USER}" 213 | echo "done!" 214 | echo -n "Ensuring that user \"${USER}\" can run 'sudo' without entering a password... " 215 | echo "${USER} ALL=(ALL) NOPASSWD:ALL" | sudo tee /etc/sudoers.d/90-"${USER}"-privileges >/dev/null 216 | sudo chmod 0440 /etc/sudoers.d/90-"${USER}"-privileges 217 | echo "done!" 218 | echo "If it continues to ask for a password below, do the following:" 219 | echo "- press CTRL-c to stop the execution of this install script" 220 | echo "- type \"exit\" to log out from your machine" 221 | echo "- log in again" 222 | echo "- re-run this script using the same command as you did before" 223 | echo 224 | fi 225 | else 226 | echo "Your account, \"${USER}\", is already part of the \"sudo\" group. Great!" 227 | fi 228 | 229 | echo "We will now continue and install Docker." 230 | echo -n "Checking for an existing Docker installation... " 231 | if which docker >/dev/null 2>&1 232 | then 233 | echo "found! Skipping Docker installation" 234 | else 235 | echo "not found!" 236 | echo "Installing docker, each step may take a while:" 237 | curl -fsSL https://get.docker.com | sudo sh 238 | echo "Docker installed -- configuring docker..." 239 | sudo usermod -aG docker "${USER}" 240 | sudo mkdir -p /etc/docker 241 | sudo chmod a+rwx /etc/docker 242 | cat > /etc/docker/daemon.json <> ~/.bashrc 255 | export PATH=/usr/bin:$PATH 256 | fi 257 | 258 | sudo systemctl restart docker.service docker.socket 259 | echo "Now let's run a test container:" 260 | if sudo docker run --rm hello-world 261 | then 262 | echo "" 263 | echo "Did you see the \"Hello from Docker! \" message above?" 264 | echo "If yes, all is good! If not, press CTRL-C and trouble-shoot." 265 | echo "" 266 | echo "Note - in order to run your containers as user \"${USER}\" (and without \"sudo\"), you should" 267 | echo "log out and log back into your Raspberry Pi once the installation is all done." 268 | echo "" 269 | read -r -p "Press ENTER to continue." 270 | else 271 | echo "" 272 | echo "Something went wrong -- this will probably be fixed with a system reboot" 273 | echo "You can continue to install all the other things using this script, and then reboot the system." 274 | echo "After the reboot, give this command to check that everything works well:" 275 | echo "" 276 | echo "docker run --rm hello-world" 277 | echo "" 278 | read -r -p "Press ENTER to continue." 279 | fi 280 | fi 281 | 282 | grep -qs COMPOSE_BAKE ~/.bashrc || echo "export COMPOSE_BAKE=true" >> ~/.bashrc 283 | 284 | echo "Adding some handy aliases to your bash shell. You can find them by typing \"cat ~/.sdre_aliases\"" 285 | curl -sSL "https://raw.githubusercontent.com/sdr-enthusiasts/docker-install/main/bash_aliases" > ~/.sdre_aliases 286 | grep -qs sdre_aliases ~/.bashrc || echo "source ~/.sdre_aliases" >> ~/.bashrc 287 | source ~/.sdre_aliases 288 | 289 | echo -n "Checking for Docker Compose installation... " 290 | if which docker-compose >/dev/null 2>&1; then 291 | echo "found! No need to install..." 292 | elif docker compose version >/dev/null 2>&1; then 293 | echo "Docker Compose plugin found. Creating an alias to it for \"docker-compose \"..." 294 | echo "alias docker-compose=\"docker compose\"" >> ~/.sdre_aliases 295 | source ~/.sdre_aliases 296 | else 297 | echo "not found!" 298 | echo "Installing Docker compose... " 299 | sudo apt install -y docker-compose-plugin 300 | if docker compose version 301 | then 302 | echo "Docker compose was installed successfully. You can use either \"docker compose\" or \"docker-compose\", they are aliases of each other" 303 | else 304 | echo "Docker-compose was not installed correctly - you may need to do this manually." 305 | fi 306 | fi 307 | 308 | # Now make sure that libseccomp2 >= version 2.4. This is necessary for Bullseye-based containers 309 | # This is often an issue on Buster and Stretch-based host systems with 32-bits Rasp Pi OS installed pre-November 2021. 310 | # The following code checks and corrects this - see also https://github.com/fredclausen/Buster-Docker-Fixes 311 | echo "Checking that your system has a current version of libseccomp2." 312 | echo "This is necessary to run Bullseye and later based containers on a Buster or Stretch based system..." 313 | OS_VERSION="$(sed -n 's/\(^\s*VERSION_CODENAME=\)\(.*\)/\2/p' /etc/os-release)" 314 | [[ "$OS_VERSION" == "" ]] && OS_VERSION="$(sed -n 's/^\s*VERSION=.*(\(.*\)).*/\1/p' /etc/os-release)" 315 | OS_VERSION=${OS_VERSION^^} 316 | 317 | if [[ "${OS_VERSION}" == "BUSTER" ]] || [[ "${OS_VERSION}" == "STRETCH" ]]; then 318 | LIBVERSION="$(apt-cache policy libseccomp2 | grep -e libseccomp2: -A1 | tail -n1)" 319 | LIBVERSION_MAJOR="$(sed -n 's/.*:\s*\([0-9]*\).\([0-9]*\).*/\1/p' <<< "$LIBVERSION")" 320 | LIBVERSION_MINOR="$(sed -n 's/.*:\s*\([0-9]*\).\([0-9]*\).*/\2/p' <<< "$LIBVERSION")" 321 | 322 | if (( LIBVERSION_MAJOR < 2 )) || (( LIBVERSION_MAJOR == 2 && LIBVERSION_MINOR < 4 )) && [[ "${OS_VERSION}" == "BUSTER" ]] 323 | then 324 | echo "libseccomp2 needs updating. Please wait while we do this." 325 | sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 04EE7237B7D453EC 648ACFD622F3D138 0E98404D386FA1D9 6ED0E7B82643E131 326 | echo "deb http://deb.debian.org/debian buster-backports main" | sudo tee -a /etc/apt/sources.list.d/buster-backports.list 327 | sudo apt update -y 328 | sudo apt install -y -q -t buster-backports libseccomp2 329 | elif (( LIBVERSION_MAJOR < 2 )) || (( LIBVERSION_MAJOR == 2 && LIBVERSION_MINOR < 4 )) && [[ "${OS_VERSION}" == "STRETCH" ]] 330 | then 331 | echo "libseccomp2 needs updating. Please wait while we do this." 332 | INSTALL_CANDIDATE="$(curl -qsL http://ftp.debian.org/debian/pool/main/libs/libseccomp/ | w3m -T text/html -dump | sed -n 's/^.*\(libseccomp2_2.5.*armhf.deb\).*/\1/p' | sort | tail -1)" 333 | curl -qsL -o /tmp/"${INSTALL_CANDIDATE}" http://ftp.debian.org/debian/pool/main/libs/libseccomp/"${INSTALL_CANDIDATE}" 334 | sudo dpkg -i /tmp/"${INSTALL_CANDIDATE}" && rm -f /tmp/"${INSTALL_CANDIDATE}" 335 | else 336 | echo "Your system already has an acceptable version of libseccomp2. Doing some final checks on that now..." 337 | fi 338 | # Now make sure all went well 339 | LIBVERSION="$(apt-cache policy libseccomp2 | grep -e libseccomp2: -A1 | tail -n1)" 340 | LIBVERSION_MAJOR="$(sed -n 's/.*:\s*\([0-9]*\).\([0-9]*\).*/\1/p' <<< "$LIBVERSION")" 341 | LIBVERSION_MINOR="$(sed -n 's/.*:\s*\([0-9]*\).\([0-9]*\).*/\2/p' <<< "$LIBVERSION")" 342 | if (( LIBVERSION_MAJOR > 2 )) || (( LIBVERSION_MAJOR == 2 && LIBVERSION_MINOR >= 4 )) 343 | then 344 | echo "Your system (now) uses libseccomp2 version $(apt-cache policy libseccomp2|sed -n 's/\s*Installed:\s*\(.*\)/\1/p')." 345 | else 346 | echo "Something went wrong. Your system is using libseccomp2 v$(apt-cache policy libseccomp2|sed -n 's/\s*Installed:\s*\(.*\)/\1/p'), and it needs to be v2.4 or greater for the ADSB containers to work properly." 347 | echo "Please follow these instructions to fix this after this install script finishes: https://github.com/fredclausen/Buster-Docker-Fixes" 348 | read -r -p "Press ENTER to continue." 349 | fi 350 | else 351 | echo "Your system is not BUSTER or STRETCH based, so there should be no problem with libseccomp2." 352 | fi 353 | 354 | echo 355 | echo "Do you want to prepare the system for use with any of the RTL-SDR / ADS-B containers?" 356 | echo "Examples of these include the collection of containers maintained by SDR-Enthusiasts group:" 357 | echo "Ultrafeeder, Tar1090, Readsb-ProtoBuf, Acarshub, PlaneFence, PiAware, RadarVirtuel, FR24, other feeders, etc." 358 | echo "It's safe to say YES to this question and continue unless you are using a DVB-T stick to watch digital television." 359 | echo 360 | read -r -p "Please choose yes or no [Y/n] > " -n 1 text 361 | if [[ "${text,,}" != "n" ]]; then 362 | echo 363 | echo -n "Getting the latest UDEV rules... " 364 | sudo mkdir -p -m 0755 /etc/udev/rules.d /etc/udev/hwdb.d 365 | # First install the UDEV rules for RTL-SDR dongles 366 | sudo -E "$(which bash)" -c "curl -sL -o /etc/udev/rules.d/rtl-sdr.rules https://raw.githubusercontent.com/wiedehopf/adsb-scripts/master/osmocom-rtl-sdr.rules" 367 | sudo -E "$(which bash)" -c "curl -sL -o /etc/udev/rules.d/dump978-fa.rules https://raw.githubusercontent.com/flightaware/dump978/master/debian/dump978-fa.udev" 368 | # Now install the UDEV rules for SDRPlay devices 369 | sudo -E "$(which bash)" -c "curl -sL -o /etc/udev/rules.d/66-mirics.rules https://raw.githubusercontent.com/sdr-enthusiasts/install-libsdrplay/main/66-mirics.rules" 370 | sudo -E "$(which bash)" -c "curl -sL -o /etc/udev/hwdb.d/20-sdrplay.hwdb https://raw.githubusercontent.com/sdr-enthusiasts/install-libsdrplay/main/20-sdrplay.hwdb" 371 | # make sure the permissions are set correctly 372 | sudo -E "$(which bash)" -c "chmod a+rX /etc/udev/rules.d /etc/udev/hwdb.d" 373 | sudo -E "$(which bash)" -c "chmod go+r /etc/udev/rules.d/* /etc/udev/hwdb.d/*" 374 | # Next, exclude the drivers so the dongles stay accessible 375 | echo -n "Excluding and unloading any competing RTL-SDR drivers... " 376 | UNLOAD_SUCCESS=true 377 | for module in "${BLOCKED_MODULES[@]}"; do 378 | if ! grep -q "$module" /etc/modprobe.d/exclusions-rtl2832.conf; then 379 | sudo -E "$(which bash)" -c "echo blacklist $module >>/etc/modprobe.d/exclusions-rtl2832.conf" 380 | sudo -E "$(which bash)" -c "echo install $module /bin/false >>/etc/modprobe.d/exclusions-rtl2832.conf" 381 | sudo -E "$(which bash)" -c "modprobe -r $module 2>/dev/null" || UNLOAD_SUCCESS=false 382 | fi 383 | done 384 | # Rebuild module dependency database factoring in blacklists 385 | if which depmod >/dev/null 2>&1; then 386 | sudo depmod -a >/dev/null 2>&1 || UNLOAD_SUCCESS=false 387 | else 388 | UNLOAD_SUCCESS=false 389 | fi 390 | # On systems with initramfs, this needs to be updated to make sure the exclusions take effect: 391 | if which update-initramfs >/dev/null 2>&1; then 392 | sudo update-initramfs -u >/dev/null 2>&1 || true 393 | fi 394 | 395 | if [[ "${UNLOAD_SUCCESS}" == false ]]; then 396 | echo "INFO: Although we've successfully excluded any competing RTL-SDR drivers, we weren't able to unload them. This will remedy itself when you reboot your system after the script finishes." 397 | fi 398 | fi 399 | echo "Making sure commands will persist when the terminal closes..." 400 | sudo loginctl enable-linger "$(whoami)" >/dev/null 2>&1 || true 401 | # 402 | # The following prevents DHCPCD based systems from trying to assign IP addresses to each of the Docker containers. 403 | # Note that this is not needed or available if the system uses DHCPD instead of DHCPCD. 404 | if [[ -f /etc/dhcpcd.conf ]] && ! grep "denyinterfaces veth\*" /etc/dhcpcd.conf >/dev/null 2>&1 405 | then 406 | echo -n "Excluding veth interfaces from dhcp. This will prevent problems if you are connected to the internet via WiFi when running many Docker containers... " 407 | sudo sh -c 'echo "denyinterfaces veth*" >> /etc/dhcpcd.conf' 408 | sudo systemctl is-enabled dhcpcd.service && sudo systemctl restart dhcpcd.service 409 | echo "done!" 410 | fi 411 | 412 | # Add some aliases to localhost in `/etc/hosts`. This will speed up recreation of images with docker-compose 413 | if ! grep localunixsocket /etc/hosts >/dev/null 2>&1 414 | then 415 | echo "Speeding up the recreation of containers when using docker-compose..." 416 | sudo sed -i 's/^\(127.0.0.1\s*localhost\)\(.*\)/\1\2 localunixsocket localunixsocket.local localunixsocket.home/g' /etc/hosts 417 | fi 418 | 419 | echo "Adding a crontab entry to ensure your system stays clean" 420 | file="$(mktemp)" 421 | crontab -l > "$file" || true 422 | { echo '#' 423 | echo '# Delete all unused containers (except those labeled do_not_prune) nightly at 3 AM' 424 | echo '# For example, docker-baseimage:rtlsdr is marked do_not_prune because it is used as a bash alias in rtl_test' 425 | echo '0 3 * * * /usr/bin/docker system prune -af --filter "label!=do_not_prune" >/dev/null 2>&1' 426 | echo '#' 427 | echo '# Delete all unused containers (incl those labeled do_not_prune) weekly at 3 AM' 428 | echo '0 4 * * 0 /usr/bin/docker system prune -af >/dev/null 2>&1' 429 | } >> "$file" 430 | crontab - < "$file" 431 | rm -f "$file" 432 | cat << "EOM" 433 | -------------------------------- 434 | We're done! Here are some final messages, read them carefully: 435 | We've installed these packages, and we think they may be useful for you in the future. So we will leave them installed: 436 | jq, git, rtl-sdr 437 | If you don't want them, feel free to uninstall them using this command: 438 | sudo apt-get remove jq git rtl-sdr 439 | 440 | We have also installed chrony as NTP (time updating) client on your system. This has probably replaced any other NTP client you may have been using. 441 | We're using chrony because this has proven to be the most stable way of keeping your system clock up to date, which is imperative for our containers to work properly. 442 | 443 | -------------------------------- 444 | To make sure that everything works OK, you should reboot your machine. 445 | Once rebooted, you are ready to go! For safety reasons, we won't do the reboot for you, but you can do it manually by typing: 446 | 447 | sudo reboot 448 | 449 | WARNING - if you are connected remotely to a Raspberry Pi (via SSH or VNC) 450 | make sure you unplug any externally powered USB devices or hubs before rebooting 451 | because these may cause your Raspberry Pi to get stuck in the \"off\" state! 452 | 453 | -------------------------------- 454 | That is all -- thanks for using our docker-install script. You are now ready to create docker-compose.yml files and start running containers! 455 | EOM 456 | -------------------------------------------------------------------------------- /sample-docker-compose.yml: -------------------------------------------------------------------------------- 1 | ###################################################################################################################################### 2 | # This sample docker-compose.yml file contains example service definitions for many of the SDR-Enthusiasts containers 3 | # It works in combination with a ".env" file, which contains some of the variables referred to in this file. 4 | # The general assumption is that both this "docker-compose.yml" file and the accompanying ".env" file will be 5 | # stored in /opt/adsb. If you use a different directory, you may need to adjust some of the volume definitions. 6 | # 7 | # Copyright 2021-2023 Ramon F. Kolb (kx1t) - licensed under the terms and conditions 8 | # of the MIT license. The terms and conditions of this license are included with the Github 9 | # distribution of this package. 10 | # 11 | ###################################################################################################################################### 12 | 13 | services: 14 | ###################################################################################################################################### 15 | # ADS-B/UAT Data Processing Services. These containers read data from dongles and/or other containers and decode or process this data. 16 | # Containers include: 17 | # ultrafeeder 18 | # dump978 19 | # 20 | # In order to temporarily suspend a container and prevent it from starting, uncomment this from each container definition: 21 | # # profiles: 22 | # # - donotstart 23 | 24 | ultrafeeder: 25 | # ultrafeeder combines a number of functions: 26 | # - it retrieves and decodes 1090MHz Mode A/C/S data from the SDR(s) using Wiedehopf's branch of readsb 27 | # - it implements a `tar1090` based map on port 80 (mapped to port 8080 on the host) 28 | # - it includes graph1090 (system statistics website) on http://xxxxx/graphs1090 29 | # - it sends ADSB data directly (without the need of additional containers) to the 30 | # "new" aggregators, and, if desired, also to AdsbExchange 31 | # - it includes mlat-client to send MLAT data to these aggregators 32 | # - it includes an MLAT Hub to consolidate MLAT results and make them available to the built-in map and other services 33 | # Note - remove "adsb,dump978,37981,raw_in;" from the ULTRAFEEDER_CONFIG parameter if your station doesn't support UAT. 34 | 35 | image: ghcr.io/sdr-enthusiasts/docker-adsb-ultrafeeder 36 | container_name: ultrafeeder 37 | hostname: ultrafeeder 38 | restart: always 39 | device_cgroup_rules: 40 | - 'c 189:* rwm' 41 | ports: 42 | - 8080:80 # to expose the web interface 43 | - 9273-9274:9273-9274 # to expose the statistics interface to Prometheus 44 | environment: 45 | # -------------------------------------------------- 46 | # general parameters: 47 | - LOGLEVEL=error 48 | - TZ=${FEEDER_TZ} 49 | # -------------------------------------------------- 50 | # SDR related parameters: 51 | - READSB_DEVICE_TYPE=rtlsdr 52 | - READSB_RTLSDR_DEVICE=${ADSB_SDR_SERIAL} 53 | - READSB_RTLSDR_PPM=${ADSB_SDR_PPM} 54 | # 55 | # -------------------------------------------------- 56 | # readsb/decoder parameters: 57 | - READSB_LAT=${FEEDER_LAT} 58 | - READSB_LON=${FEEDER_LONG} 59 | - READSB_ALT=${FEEDER_ALT_M}m 60 | - READSB_RX_LOCATION_ACCURACY=2 61 | - READSB_STATS_RANGE=true 62 | # 63 | # -------------------------------------------------- 64 | # Sources and Aggregator connections: 65 | # Notes - remove the entries you are not using / feeding 66 | # - !!! make sure that each line ends with a semicolon ";" !!! 67 | - ULTRAFEEDER_CONFIG= 68 | adsb,dump978,30978,uat_in; 69 | adsb,feed.adsb.fi,30004,beast_reduce_plus_out; 70 | adsb,in.adsb.lol,30004,beast_reduce_plus_out; 71 | adsb,feed.airplanes.live,30004,beast_reduce_plus_out; 72 | adsb,feed.planespotters.net,30004,beast_reduce_plus_out; 73 | adsb,feed.theairtraffic.com,30004,beast_reduce_plus_out; 74 | adsb,data.avdelphi.com,24999,beast_reduce_plus_out; 75 | adsb,skyfeed.hpradar.com,30004,beast_reduce_plus_out; 76 | adsb,feed.radarplane.com,30001,beast_reduce_plus_out; 77 | adsb,dati.flyitalyadsb.com,4905,beast_reduce_plus_out; 78 | adsb,feed1.adsbexchange.com,30004,beast_reduce_plus_out; 79 | mlat,feed.adsb.fi,31090; 80 | mlat,in.adsb.lol,31090; 81 | mlat,feed.airplanes.live,31090; 82 | mlat,mlat.planespotters.net,31090; 83 | mlat,feed.theairtraffic.com,31090; 84 | mlat,skyfeed.hpradar.com,31090; 85 | mlat,feed.radarplane.com,31090; 86 | mlat,dati.flyitalyadsb.com,30100; 87 | mlat,feed.adsbexchange.com,31090; 88 | mlathub,piaware,30105,beast_in; 89 | mlathub,airnavradar,30105,beast_in; 90 | mlathub,radarvirtuel,30105,beast_in; 91 | mlathub,planewatch,30105,beast_in; 92 | # If you are in the Netherlands or close to its borders, please add the following aggregator: 93 | # adsb,feed.hetluchtruim.nl,9000,beast_reduce_plus_out; 94 | # 95 | # If you really want to feed ADSBExchange, you can do so by adding this above: 96 | # # (the ",uuid=${ADSBX_UUID}" part is optional) 97 | # 98 | # -------------------------------------------------- 99 | - UUID=${ULTRAFEEDER_UUID} 100 | - MLAT_USER=${FEEDER_NAME} 101 | # 102 | # -------------------------------------------------- 103 | # TAR1090 (Map Web Page) parameters: 104 | - UPDATE_TAR1090=true 105 | - TAR1090_DEFAULTCENTERLAT=${FEEDER_LAT} 106 | - TAR1090_DEFAULTCENTERLON=${FEEDER_LONG} 107 | - TAR1090_MESSAGERATEINTITLE=true 108 | - TAR1090_PAGETITLE=${FEEDER_NAME} 109 | - TAR1090_PLANECOUNTINTITLE=true 110 | - TAR1090_ENABLE_AC_DB=true 111 | - TAR1090_FLIGHTAWARELINKS=true 112 | - HEYWHATSTHAT_PANORAMA_ID=${FEEDER_HEYWHATSTHAT_ID} 113 | - HEYWHATSTHAT_ALTS=${FEEDER_HEYWHATSTHAT_ALTS} 114 | - TAR1090_SITESHOW=true 115 | - TAR1090_RANGE_OUTLINE_COLORED_BY_ALTITUDE=true 116 | - TAR1090_RANGE_OUTLINE_WIDTH=2.0 117 | - TAR1090_RANGERINGSDISTANCES=50,100,150,200 118 | - TAR1090_RANGERINGSCOLORS='#1A237E','#0D47A1','#42A5F5','#64B5F6' 119 | - TAR1090_USEROUTEAPI=true 120 | # 121 | # -------------------------------------------------- 122 | # GRAPHS1090 (Decoder and System Status Web Page) parameters: 123 | # The two 978 related parameters should only be included if you are running dump978 for UAT reception (USA only) 124 | - GRAPHS1090_DARKMODE=true 125 | # - ENABLE_978=yes 126 | # - URL_978=http://dump978/skyaware978 127 | # 128 | # -------------------------------------------------- 129 | # Prometheus and InfluxDB connection parameters: 130 | # If you enable these, you must vent the image: line above to # 131 | # image: ghcr.io/sdr-enthusiasts/docker-adsb-ultrafeeder:telegraf 132 | # - INFLUXDBV2_URL=${INFLUX_URL} 133 | # - INFLUXDBV2_TOKEN=${INFLUX_TOKEN} 134 | # - INFLUXDBV2_BUCKET=${INFLUX_BUCKET} 135 | # - PROMETHEUS_ENABLE=true 136 | volumes: 137 | - /opt/adsb/ultrafeeder/globe_history:/var/globe_history 138 | - /opt/adsb/ultrafeeder/graphs1090:/var/lib/collectd 139 | - /proc/diskstats:/proc/diskstats:ro 140 | - /dev/bus/usb:/dev/bus/usb 141 | tmpfs: 142 | - /run:exec,size=256M 143 | - /tmp:size=128M 144 | - /var/log:size=32M 145 | 146 | dump978: 147 | # dump978 gets UAT data from the SDR 148 | image: ghcr.io/sdr-enthusiasts/docker-dump978 149 | # profiles: 150 | # - donotstart 151 | container_name: dump978 152 | hostname: dump978 153 | restart: always 154 | labels: 155 | - "autoheal=true" 156 | device_cgroup_rules: 157 | - 'c 189:* rwm' 158 | environment: 159 | - TZ=${FEEDER_TZ} 160 | - DUMP978_RTLSDR_DEVICE=${UAT_SDR_SERIAL} 161 | - DUMP978_SDR_GAIN=${UAT_SDR_GAIN} 162 | - DUMP978_SDR_PPM=${UAT_SDR_PPM} 163 | - LAT=${FEEDER_LAT} 164 | - LON=${FEEDER_LONG} 165 | - ENABLE_PROMETHEUS=true # set to true if you are configuring Prometheus/Grafana dashboards 166 | ports: 167 | - 30979:30979 168 | - 30978:30978 169 | - 30980:80 170 | - 9275:9273 171 | volumes: 172 | - /opt/adsb/dump978/autogain:/run/autogain 173 | - /dev/bus/usb:/dev/bus/usb 174 | tmpfs: 175 | - /run/readsb 176 | 177 | ###################################################################################################################################### 178 | # ADS-B Feeder Services. These containers feed ADS-B/UAT data to aggregator services. 179 | # Containers include: 180 | # piaware (FlightAware) 181 | # fr24 (FlightRadar24) 182 | # pfclient (Planefinder) 183 | # airnavradar (AirNav Radar (a.k.a RadarBox)) 184 | # radarvirtuel (RadarVirtuel) 185 | # planewatch (Plane.Watch) 186 | # ADSBHub (ADSB Hub) 187 | 188 | piaware: 189 | # piaware feeds ADS-B and UAT data (from ultrafeeder) to FlightAware. It also includes a GUI Radar website and a status website 190 | # If you're not capturing UAT data with the dump978 container, remove or comment out the UAT_RECEIVER_TYPE and UAT_RECEIVER_HOST lines in the environment section below. 191 | image: ghcr.io/sdr-enthusiasts/docker-piaware 192 | # profiles: 193 | # - donotstart 194 | container_name: piaware 195 | hostname: piaware 196 | restart: always 197 | labels: 198 | - "autoheal=true" 199 | ports: 200 | - 8081:8080 201 | - 8088:80 202 | environment: 203 | - BEASTHOST=ultrafeeder 204 | - LAT=${FEEDER_LAT} 205 | - LONG=${FEEDER_LONG} 206 | - TZ=${FEEDER_TZ} 207 | - FEEDER_ID=${PIAWARE_FEEDER_ID} 208 | - UAT_RECEIVER_TYPE=relay 209 | - UAT_RECEIVER_HOST=dump978 210 | tmpfs: 211 | - /run:exec,size=64M 212 | - /var/log 213 | 214 | 215 | fr24: 216 | # fr24 feeds ADS-B and UAT data (from ultrafeeder) to FlightRadar24. It also includes a status website. Please be careful 217 | # not to expose the status website to the internet as users may be able to start/stop/change the service from there. 218 | # Also note that FR24 has requested NOT to enable MLAT for those station that feed to multiple services; as such, it's commented out. 219 | image: ghcr.io/sdr-enthusiasts/docker-flightradar24 220 | # profiles: 221 | # - donotstart 222 | container_name: fr24 223 | hostname: fr24 224 | restart: always 225 | labels: 226 | - "autoheal=true" 227 | ports: 228 | - 8754:8754 229 | environment: 230 | - BEASTHOST=ultrafeeder 231 | - TZ=${FEEDER_TZ} 232 | - FR24KEY=${FR24_SHARING_KEY} 233 | # - MLAT=yes 234 | tmpfs: 235 | - /var/log 236 | 237 | pfclient: 238 | # pfclient feeds ADS-B and UAT data (from ultrafeeder) to Plane Finder. It also includes a GUI Radar website and a status website 239 | image: ghcr.io/sdr-enthusiasts/docker-planefinder:latest 240 | # profiles: 241 | # - donotstart 242 | container_name: pfclient 243 | restart: always 244 | ports: 245 | - 8084:30053 246 | environment: 247 | - BEASTHOST=ultrafeeder 248 | - LAT=${FEEDER_LAT} 249 | - LONG=${FEEDER_LONG} 250 | - TZ=${FEEDER_TZ} 251 | - SHARECODE=${PLANEFINDER_SHARECODE} 252 | 253 | airnavradar: 254 | # airnavradar feeds ADS-B and UAT data (from ultrafeeder) to AirNav Radar. 255 | # If you're not capturing UAT data with the dump978 container, remove or comment out the UAT_RECEIVER_HOST line in the environment section below. 256 | image: ghcr.io/sdr-enthusiasts/docker-airnavradar 257 | # profiles: 258 | # - donotstart 259 | container_name: airnavradar 260 | hostname: airnavradar 261 | restart: always 262 | labels: 263 | - "autoheal=true" 264 | environment: 265 | - BEASTHOST=ultrafeeder 266 | - UAT_RECEIVER_HOST=dump978 267 | - LAT=${FEEDER_LAT} 268 | - LONG=${FEEDER_LONG} 269 | - ALT=${FEEDER_ALT_M} 270 | - TZ=${FEEDER_TZ} 271 | - SHARING_KEY=${AIRNAVRADAR_SHARING_KEY} 272 | tmpfs: 273 | - /run:exec,size=64M 274 | - /var/log 275 | 276 | radarvirtuel: 277 | # radarvirtuel feeds ADS-B and UAT data (from ultrafeeder) to RadarVirtuel. 278 | image: ghcr.io/sdr-enthusiasts/docker-radarvirtuel 279 | # profiles: 280 | # - donotstart 281 | container_name: radarvirtuel 282 | hostname: radarvirtuel 283 | restart: always 284 | environment: 285 | - FEEDER_KEY=${RV_KEY} 286 | - SOURCE_HOST=ultrafeeder:30002 287 | - RV_SERVER=mg22.adsbnetwork.com:50050 288 | - LAT=${FEEDER_LAT} 289 | - LON=${FEEDER_LONG} 290 | - ALT=${FEEDER_ALT_M}m 291 | - MLAT_SERVER=mlat.adsbnetwork.com:50000 292 | - MLAT_HOST=ultrafeeder:30005 293 | - MLAT_INPUT_TYPE=auto 294 | - VERBOSE=ON 295 | tmpfs: 296 | - /tmp:rw,nosuid,nodev,noexec,relatime,size=128M 297 | volumes: 298 | - "/etc/localtime:/etc/localtime:ro" 299 | - "/etc/timezone:/etc/timezone:ro" 300 | 301 | planewatch: 302 | # planewatch feeds ADS-B and UAT data (from ultrafeeder) to Plane.Watch. 303 | image: ghcr.io/plane-watch/docker-plane-watch 304 | # profiles: 305 | # - donotstart 306 | container_name: planewatch 307 | hostname: planewatch 308 | restart: always 309 | environment: 310 | - BEASTHOST=ultrafeeder 311 | - TZ=${FEEDER_TZ} 312 | - API_KEY=${PLANEWATCH_KEY} 313 | - ACARS_HOST=acars_router 314 | - VDLM2_HOST=acars_router 315 | - DEBUG_LOGGING=true 316 | - LAT=${FEEDER_LAT} 317 | - LONG=${FEEDER_LONG} 318 | - ALT=${FEEDER_ALT_FT}ft 319 | tmpfs: 320 | - /run:exec,size=64M 321 | - /var/log 322 | 323 | 324 | adsbhub: 325 | # adsbhub feeds ADS-B and UAT data (from ultrafeeder) to ADSB Hub. 326 | image: ghcr.io/sdr-enthusiasts/docker-adsbhub 327 | # profiles: 328 | # - donotstart 329 | container_name: adsbhub 330 | restart: always 331 | environment: 332 | - TZ=${FEEDER_TZ} 333 | - SBSHOST=ultrafeeder 334 | - CLIENTKEY=${ADSBHUB_STATION_KEY} 335 | 336 | 337 | ###################################################################################################################################### 338 | # ADS-B Visualization Services. These containers create pretty web pages from ADSB/UAT data that your station receives. 339 | # Containers include: 340 | # planefence (monitor planes nearby your station and planes from a "special" watchlist) 341 | # screenshot (auxiliary container used with planefence -- only runs well on Pi4) 342 | # vrs: Virtual Radar Server 343 | 344 | planefence: 345 | # Note - after initial startup, please edit /opt/adsb/planefence/config/planefence.config. Then restart this container. 346 | image: ghcr.io/sdr-enthusiasts/docker-planefence 347 | # profiles: 348 | # - donotstart 349 | container_name: planefence 350 | hostname: planefence 351 | restart: always 352 | ports: 353 | - 8083:80 354 | environment: 355 | - TZ=${FEEDER_TZ} 356 | volumes: 357 | - /opt/adsb/planefence/config:/usr/share/planefence/persist 358 | - /opt/adsb/planefence/html:/usr/share/planefence/html 359 | tmpfs: 360 | - /run:rw,nosuid,nodev,exec,relatime,size=256M 361 | - /tmp:rw,nosuid,nodev,noexec,relatime,size=128M 362 | 363 | screenshot: 364 | image: ghcr.io/kx1t/screenshot 365 | # profiles: 366 | # - donotstart 367 | container_name: screenshot 368 | hostname: screenshot 369 | restart: always 370 | shm_size: 1gb 371 | environment: 372 | - MAP_ARGS=zoom=11.5&hideSidebar&hideButtons&mapDim=0.2&monochromeMarkers=ff0000&outlineColor=505050&iconScale=1.5&enableLabels&extendedLabels=2&trackLabels 373 | - LOAD_SLEEP_TIME=25 374 | - BASE_URL=http://tar1090 375 | - DISABLE_SHM=true 376 | - MAXTIME=60 377 | 378 | vrs: 379 | image: ghcr.io/sdr-enthusiasts/vrs:dev 380 | # profiles: 381 | # - do_not_start 382 | container_name: vrs 383 | hostname: vrs 384 | restart: always 385 | ports: 386 | - 8091:8080 387 | - 49000-49099:49000-49099 388 | environment: 389 | - VRS_ADMIN_USERNAME=${VRS_ADMIN_USERNAME} 390 | - VRS_ADMIN_PASSWORD=${VRS_ADMIN_PASSWORD} 391 | - VRS_DB_UPDATE_POLICY_FULLAUTO=on 392 | - VRS_CULTURE=en-US #see http://msdn.microsoft.com/en-us/goglobal/bb896001.aspx for a list of supported culture names. Not all translations may be available 393 | - VRS_DB_UPDATE_POLICY_FULLAUTO=yes #default unset / no 394 | - VRS_DB_UPDATE_WITH_VACUUM=yes #default unset / no 395 | - VRS_DB_UPDATE_BACKUP_UNCOMPRESSED=yes #default unset / compressed 396 | - VRS_ENHANCED_MARKERS=hfdl #default unset 397 | - VRS_ENHANCED_LAYERS_COUNTRY=USA1 #Currently available: UK,DE,USA1,SE 398 | tmpfs: 399 | - /tmp:rw,nosuid,nodev,noexec,relatime,size=128M 400 | volumes: 401 | - /opt/adsb/vrs:/root/.local/share/VirtualRadar 402 | - "/etc/localtime:/etc/localtime:ro" 403 | - "/etc/timezone:/etc/timezone:ro" 404 | 405 | ###################################################################################################################################### 406 | # Additional aircraft related containers: airband 407 | # This container allows listening to Airband radio and feeding this data to AirNav Radar. It also creates a local Icecast station you can 408 | # listen to. 409 | 410 | airband: 411 | image: ghcr.io/sdr-enthusiasts/docker-rtlsdrairband:latest_nohealthcheck 412 | # profiles: 413 | # - donotstart 414 | container_name: airband 415 | restart: always 416 | device_cgroup_rules: 417 | - 'c 189:* rwm' 418 | ports: 419 | - 8000:8000 420 | environment: 421 | - RTLSDRAIRBAND_CUSTOMCONFIG=true 422 | # - ICECAST_CUSTOMCONFIG=true 423 | volumes: 424 | - /opt/adsb/rtlsdr-airband:/run/rtlsdr-airband 425 | - /dev/bus/usb:/dev/bus/usb 426 | 427 | ###################################################################################################################################### 428 | # Additional aircraft related containers: ACARS/VDLM 429 | # With these containers, you can receive and look at ACARS and VDL-M2 messages and feed those to ariframes.io. 430 | # Note that the plane.watch container is also set up to forward these messages. 431 | # The set consists of the following containers: 432 | # acarsdec: receives and decodes ACARS data from a dedicated RTL-SDR dongle 433 | # dumpvdl2: receives and decodes VDL-M2 data from a dedicated RTL-SDR dongle 434 | # acars_router: functions as an aggregator/distributor of the received ACARS and VDL-M2 data 435 | # acarshub: visualization tool for ACARS and VDL-M2 data 436 | 437 | acarsdec: 438 | image: ghcr.io/sdr-enthusiasts/docker-acarsdec:latest 439 | # profiles: 440 | # - donotstart 441 | container_name: acarsdec 442 | restart: always 443 | device_cgroup_rules: 444 | - 'c 189:* rwm' 445 | environment: 446 | - TZ=${FEEDER_TZ} 447 | - SOAPYSDR=driver=rtlsdr,serial=${ACARS_SDR_SERIAL} 448 | - FREQUENCIES=${ACARS_FREQUENCIES} 449 | - GAIN=${ACARS_SDR_GAIN} 450 | - OUTPUT_SERVER=acars_router 451 | - OUTPUT_SERVER_PORT=5550 452 | - FEED_ID=${ACARS_FEEDER_ID} 453 | volumes: 454 | - /dev/bus/usb:/dev/bus/usb 455 | tmpfs: 456 | - /run:exec,size=64M 457 | - /var/log 458 | 459 | dumpvdl2: 460 | image: ghcr.io/sdr-enthusiasts/docker-dumpvdl2:latest 461 | # profiles: 462 | # - donotstart 463 | container_name: dumpvdl2 464 | restart: always 465 | device_cgroup_rules: 466 | - 'c 189:* rwm' 467 | environment: 468 | - TZ=${FEEDER_TZ} 469 | - SOAPYSDR=driver=rtlsdr,serial=${VDLM_SDR_SERIAL} 470 | - FREQUENCIES=${VDLM_FREQUENCIES} 471 | - GAIN=${VDLM_SDR_GAIN} 472 | - ZMQ_MODE=server 473 | - ZMQ_ENDPOINT=tcp://0.0.0.0:45555 474 | - FEED_ID=${VDLM_FEEDER_ID} 475 | - VDLM_FILTER_ENABLE= 476 | - QUIET_LOGS=FALSE 477 | - SERVER= 478 | volumes: 479 | - /dev/bus/usb:/dev/bus/usb 480 | tmpfs: 481 | - /run:exec,size=64M 482 | - /var/log 483 | 484 | acars_router: 485 | image: ghcr.io/sdr-enthusiasts/acars_router:latest 486 | # profiles: 487 | # - donotstart 488 | container_name: acars_router 489 | restart: always 490 | environment: 491 | - TZ=${FEEDER_TZ} 492 | - AR_SEND_UDP_ACARS=acarshub:5550;feed.acars.io:5550 493 | - AR_SEND_UDP_VDLM2=acarshub:5555 494 | - AR_SEND_TCP_VDLM2=feed.acars.io:5553 495 | - AR_RECV_ZMQ_VDLM2=dumpvdl2:45555 496 | # - AR_VERBOSITY=1 497 | ports: 498 | - 15550:15550 499 | - 15555:15555 500 | tmpfs: 501 | - /run:exec,size=64M 502 | - /var/log 503 | 504 | acarshub: 505 | image: ghcr.io/sdr-enthusiasts/docker-acarshub:latest 506 | # profiles: 507 | # - donotstart 508 | container_name: acarshub 509 | hostname: acarshub 510 | restart: always 511 | ports: 512 | - 8091:80 513 | environment: 514 | - TZ=${FEEDER_TZ} 515 | - ADSB_LAT=${FEEDER_LAT} 516 | - ADSB_LON=${FEEDER_LONG} 517 | - ENABLE_ADSB=true 518 | - ADSB_URL=http://tar1090/data/aircraft.json 519 | - ENABLE_ACARS=external 520 | - ENABLE_VDLM=external 521 | volumes: 522 | - /opt/adsb/acars_data:/run/acars 523 | tmpfs: 524 | - /run:exec,size=64M 525 | - /var/log 526 | 527 | 528 | ###################################################################################################################################### 529 | # WebProxy translates unfriendly URLs like http://x.x.x.x:8091 into friendly URLs like http://x.x.x.x/acarshub 530 | # It also provides GeoIP filtering and Bot Filtering 531 | # Although it's possible (and easy) to add SSL connectivity for websites that are exposed to the Internet, 532 | # the setup below doesn't include this. 533 | # Additionally, you can host your own web pages in this directory: /opt/adsb/webproxy/html 534 | 535 | webproxy: 536 | image: ghcr.io/sdr-enthusiasts/docker-reversewebproxy 537 | # profiles: 538 | # - donotstart 539 | container_name: webproxy 540 | hostname: webproxy 541 | restart: always 542 | ports: 543 | - 80:80 544 | - 443:443 545 | extra_hosts: 546 | - "host.docker.internal:host-gateway" 547 | environment: 548 | - AUTOGENERATE=ON 549 | - VERBOSELOG=ON 550 | - GEOIP_DEFAULT=ALLOW 551 | - GEOIP_COUNTRIES=RU,CN,BY 552 | - GEOIP_RESPONSECODE=418 553 | - REVPROXY= 554 | readsb|http://host.docker.internal:8080, 555 | graphs|http://host.docker.internal:8080/graphs1090, 556 | stats|http://host.docker.internal:8080/graphs1090, 557 | radar|http://host.docker.internal:8080, 558 | tar1090|http://host.docker.internal:8080, 559 | map|http://host.docker.internal:8080, 560 | ultrafeeder|http://host.docker.internal:8080, 561 | piaware|http://host.docker.internal:8081, 562 | piaware-stats|http://host.docker.internal:8088, 563 | planefence|http://host.docker.internal:8083, 564 | plane-alert|http://host.docker.internal:8083/plane-alert, 565 | vnstat|http://host.docker.internal:8685, 566 | planefinder|http://host.docker.internal:8084,ajax|http://host.docker.internal:8084/ajax,assets|http://host.docker.internal:8084/assets, 567 | vrs|http://host.docker.internal/VirtualRadar, 568 | fam|http://host.docker.internal:8090, 569 | acarshub|http://host.docker.internal:8091 570 | - REDIRECT= 571 | /skyaware|/piaware, 572 | /fr24|http://$$host:8754, 573 | /planefinder/logs.html|http://$$host:8084/logs.html, 574 | /airband|http://$$host:8000 575 | - SSL=DISABLED 576 | - BLOCKBOT= 577 | bot,LieBaoFast,UCBrowser,MQQBrowser,Mb2345Browser,https://gdnplus.com,facebookexternalhit,http.rb, 578 | google,bing,yandex,msnbot,wp-login.php,zgrab,zgrab2,aws/config.php,wp-includes,Guzzle,Friendica, 579 | AltaVista,Googlebot,Slurp,BlackWidow,Bot,ChinaClaw,Custo,DISCo,Download,Demon,eCatch,EirGrabber,EmailSiphon,EmailWolf,SuperHTTP,Surfbot,WebWhacker, 580 | Express,WebPictures,ExtractorPro,EyeNetIE,FlashGet,GetRight,GetWeb!,Go!Zilla,Go-Ahead-Got-It,GrabNet,Grafula,HMView,Go!Zilla,Go-Ahead-Got-It, 581 | rafula,HMView,HTTrack,Stripper,Sucker,Indy,InterGET,Ninja,JetCar,Spider,larbin,LeechFTP,Downloader,tool,Navroad,NearSite,NetAnts,tAkeOut,WWWOFFLE, 582 | GrabNet,NetSpider,Vampire,NetZIP,Octopus,Offline,PageGrabber,Foto,pavuk,pcBrowser,RealDownload,ReGet,SiteSnagger,SmartDownload,SuperBot,WebSpider, 583 | Teleport,VoidEYE,Collector,WebAuto,WebCopier,WebFetch,WebGo,WebLeacher,WebReaper,WebSauger,eXtractor,Quester,WebStripper,WebZIP,Widow,Zeus, 584 | Twengabot,htmlparser,libwww,Python,perl,urllib,scan,email,PycURL,Pyth,PyQ,WebCollector,WebCopy,webcraw,PetalBot,ubermetrics,Firefox/45, 585 | Vert.x-WebClient,jsonlite,rv:45.0,Nexgate Ruby Client,scoop.it,NetSystemsResearch,Barkrowler,Python-Requests,Expanse,Go-http-client,scpitspi-rs,zgrab - BLOCKBOT_RESPONSECODE=402 586 | tmpfs: 587 | - /tmp:rw,nosuid,nodev,noexec,relatime,size=128M 588 | volumes: 589 | - /opt/adsb/webproxy:/run/nginx 590 | - "/etc/localtime:/etc/localtime:ro" 591 | - "/etc/timezone:/etc/timezone:ro" 592 | 593 | ###################################################################################################################################### 594 | # AIS (Ship and Vessel related reporting) 595 | # shipfeeder : decode AIS signals at 162 MHz and send them to aggregators including 596 | # ShipXplorer, airframes.io, HPRadar, VesselTracker, VesselFinder, MarineTraffic, aprs.fi, etc. 597 | # VesselAlert: send Mastodon and Discord notification about ships heard 598 | # screenshot-ais: add-on to VesselAlert to include screenshots in the notification 599 | # ais2adsb: add-on to ShipXplorer and VirtualRadarServer to show ships on the VRS map. 600 | 601 | shipfeeder: 602 | image: ghcr.io/sdr-enthusiasts/docker-shipfeeder 603 | container_name: shipfeeder 604 | hostname: shipfeeder 605 | restart: always 606 | environment: 607 | # general parameters: 608 | - VERBOSE_LOGGING= 609 | # ais-catcher general and website related parameters 610 | - AISCATCHER_EXTRA_OPTIONS=${SX_EXTRA_OPTIONS} 611 | - STATION_NAME=${STATION_NAME} 612 | - STATION_HISTORY=3600 613 | - BACKUP_INTERVAL=5 614 | - FEEDER_LONG=${FEEDER_LONG} 615 | - FEEDER_LAT=${FEEDER_LAT} 616 | - SITESHOW=on 617 | - PROMETHEUS_ENABLE=on 618 | - REALTIME=on 619 | # ais-catcher receiver related parameters 620 | - RTLSDR_DEVICE_SERIAL=${RTLSDR_DEVICE_SERIAL} 621 | - RTLSDR_DEVICE_GAIN=${RTLSDR_DEVICE_GAIN} 622 | - RTLSDR_DEVICE_PPM=${RTLSDR_DEVICE_PPM} 623 | - RTLSDR_DEVICE_BANDWIDTH=${RTLSDR_DEVICE_BANDWIDTH} 624 | - AISCATCHER_DECODER_AFC_WIDE=${AISCATCHER_DECODER_AFC_WIDE} 625 | # aggregrators related parameters 626 | - AIRFRAMES_STATION_ID=${AIRFRAMES_STATION_ID} 627 | - AISCATCHER_FEEDER_KEY=${AISCATCHER_FEEDER_KEY} 628 | - AISHUB_UDP_PORT=${AISHUB_UDP_PORT} 629 | - APRSFI_FEEDER_KEY=${APRSFI_FEEDER_KEY} 630 | - BOATBEACON_SHAREDATA=${BOATBEACON_SHAREDATA} 631 | - HPRADAR_UDP_PORT=${HPRADAR_UDP_PORT} 632 | - MARINETRAFFIC_UDP_PORT=${MARINETRAFFIC_UDP_PORT} 633 | - MYSHIPTRACKING_UDP_PORT=${MYSHIPTRACKING_UDP_PORT} 634 | - RADARVIRTUEL_FEEDER_KEY=${RADARVIRTUEL_FEEDER_KEY} 635 | - RADARVIRTUEL_STATION_ID=${RADARVIRTUEL_STATION_ID} 636 | - SHIPFINDER_SHAREDATA=${SHIPFINDER_SHAREDATA} 637 | - SHIPPINGEXPLORER_UDP_PORT=${SHIPPINGEXPLORER_UDP_PORT} 638 | - SHIPXPLORER_SHARING_KEY=${SHIPXPLORER_SHARING_KEY} 639 | - SHIPXPLORER_SERIAL_NUMBER=${SHIPXPLORER_SERIAL_NUMBER} 640 | - VESSELFINDER_UDP_PORT=${VESSELFINDER_UDP_PORT} 641 | - VESSELTRACKER_UDP_PORT=${VESSELTRACKER_UDP_PORT} 642 | - UDP_FEEDS=${SX_UDP_FEEDS} 643 | # incoming UDP data related parameters: 644 | - AISCATCHER_UDP_INPUTS=${AISCATCHER_UDP_INPUTS} 645 | ports: 646 | - 90:80 647 | - 9988:9988/udp 648 | device_cgroup_rules: 649 | - 'c 189:* rwm' 650 | tmpfs: 651 | - /tmp 652 | volumes: 653 | - "/etc/localtime:/etc/localtime:ro" 654 | - "/etc/timezone:/etc/timezone:ro" 655 | - "/opt/ais/shipxplorer/data:/data" 656 | - /dev/bus/usb:/dev/bus/usb 657 | # - /opt/shipxplorer/cpuinfo/cpuinfo:/proc/cpuinfo # only for x86 systems - see README.md 658 | 659 | vesselalert: 660 | image: ghcr.io/sdr-enthusiasts/docker-vesselalert 661 | container_name: vesselalert 662 | hostname: vesselalert 663 | restart: always 664 | environment: 665 | - AIS_URL=http://shipfeeder 666 | - CHECK_INTERVAL=30 667 | - MASTODON_SERVER=airwaves.social 668 | - MASTODON_ACCESS_TOKEN=${VESSELALERT_MASTODON_TOKEN} 669 | - MASTODON_SKIP_FILTER=^[9]{2}[0-9]{7}$|^[0-9]{7}$ 670 | - MASTODON_MIN_DIST=10 671 | - NOTIFICATION_MIN_DIST=10 672 | - MASTODON_CUSTOM_FIELD=${VESSELALERT_MASTODON_CUSTOM_FIELD} 673 | - MASTODON_LINK_SHIPXPLORER=on 674 | - MASTODON_LINK_MARINETRAFFIC=on 675 | - MASTODON_LINK_VESSELFINDER=on 676 | - MASTODON_ONLY_NEW_ON_STARTUP=on 677 | - MASTODON_THROTTLE=on 678 | - NOTIFICATION_MAPURL=on 679 | - DISCORD_NAME=${VESSELALERT_DISCORD_NAME} 680 | - DISCORD_AVATAR_URL=${VESSELALERT_AVATAR_URL} 681 | - DISCORD_WEBHOOKS=${VESSELALERT_DISCORD_WEBHOOKS} 682 | - SCREENSHOT_URL=http://ais-screenshot:5042 683 | tmpfs: 684 | - /tmp 685 | volumes: 686 | - /opt/ais/data:/data 687 | - "/etc/localtime:/etc/localtime:ro" 688 | - "/etc/timezone:/etc/timezone:ro" 689 | 690 | ais-screenshot: 691 | image: ghcr.io/sdr-enthusiasts/screenshot:aiscatcher 692 | container_name: ais-screenshot 693 | hostname: ais-screenshot 694 | restart: always 695 | shm_size: 1gb 696 | environment: 697 | - LOAD_SLEEP_TIME=15 698 | - BASE_URL=http://shipfeeder/?tab=map 699 | - MAXTIME=60 700 | - MAP_ARGS=map=OpenStreetMap 701 | ports: 702 | - 5043:5042 703 | 704 | ais2adsb: 705 | image: ghcr.io/jvde-github/ais2adsb:edge 706 | # profiles: 707 | # - donotstart 708 | container_name: ais2adsb 709 | hostname: ais2adsb 710 | restart: always 711 | environment: 712 | - SBS_TARGET_HOST=vrs 713 | - SBS_TARGET_PORT=49001 # adapt this to the VRS port you set up 714 | - INCLUDE_SHIPS=true # leave empty to forward only SAR aircraft 715 | 716 | ###################################################################################################################################### 717 | # Finally, a few "maintenance" containers that keep the rest of the stack healthy and up to date: 718 | # vnstat: shows network usage on a per interface (global and per container) basis 719 | # autoheal: restarts containers when they are deemed "unhealthy" 720 | # watchtower: checks every 24 hours for new versions of the containers, and downloads/installs/starts them 721 | 722 | vnstat: 723 | image: vergoh/vnstat 724 | container_name: vnstat 725 | restart: always 726 | network_mode: "host" 727 | ports: 728 | - 8685:8685 729 | volumes: 730 | - /etc/localtime:/etc/localtime:ro 731 | - /etc/timezone:/etc/timezone:ro 732 | - /opt/adsb/vnstat:/var/lib/vnstat 733 | environment: 734 | - HTTP_PORT=8685 735 | - HTTP_BIND=* 736 | - HTTP_LOG=/dev/stdout 737 | - LARGE_FONTS=1 738 | - CACHE_TIME=1 739 | - RATE_UNIT=0 740 | - PAGE_REFRESH=0 741 | - SERVER_NAME="ADSB Station IO Stats" 742 | 743 | autoheal: 744 | image: willfarrell/autoheal 745 | container_name: autoheal 746 | hostname: autoheal 747 | restart: always 748 | environment: 749 | - AUTOHEAL_CONTAINER_LABEL=all 750 | volumes: 751 | - /var/run/docker.sock:/var/run/docker.sock 752 | 753 | watchtower: 754 | image: containrrr/watchtower 755 | container_name: watchtower 756 | hostname: watchtower 757 | restart: always 758 | environment: 759 | - TZ=${FEEDER_TZ} 760 | - WATCHTOWER_CLEANUP=true 761 | - WATCHTOWER_POLL_INTERVAL=86400 762 | - WATCHTOWER_ROLLING_RESTART=true 763 | volumes: 764 | - /var/run/docker.sock:/var/run/docker.sock 765 | -------------------------------------------------------------------------------- /sample-dot-env: -------------------------------------------------------------------------------- 1 | # Config parameters for ASDB Docker Containers: 2 | # Station characteristics: 3 | FEEDER_ALT_FT= 4 | FEEDER_ALT_M= 5 | FEEDER_LAT= 6 | FEEDER_LONG= 7 | FEEDER_TZ= 8 | FEEDER_NAME= 9 | FEEDER_TZ= 10 | FEEDER_HEYWHATSTHAT_ID= 11 | FEEDER_HEYWHATSTHAT_ALTS= 12 | # 13 | # SDR parameters: 14 | # for ADSB: 15 | ADSB_SDR_SERIAL= 16 | ADSB_SDR_PPM= 17 | # for UAT: 18 | UAT_SDR_SERIAL="sdr-serial-number" 19 | UAT_SDR_GAIN=autogain 20 | UAT_SDR_PPM="sdr-ppm" 21 | # 22 | # Feeder parameters: 23 | PIAWARE_FEEDER_ID=xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx 24 | FR24_SHARING_KEY=xxxxxxxxxxxxxxx 25 | FR24_RADAR_ID=T-xxxxxx 26 | AIRNAVRADAR_SHARING_KEY=xxxxxxxxxxxxxxxxxxxxxxxxxxx 27 | ADSBHUB_STATION_KEY='xxxxxxxxxxxxxxxxxx' 28 | PLANEFINDER_SHARECODE=xxxxxxxxxxxxx 29 | PLANEWATCH_KEY=xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx 30 | RV_KEY="xxxx:xxxxxxxxxxxxxxxxxxxxx" 31 | MLAT_SITE_NAME=my_site_name 32 | ULTRAFEEDER_UUID= 33 | # 34 | # VRS parameters: 35 | VRS_ADMIN_USERNAME=admin 36 | VRS_ADMIN_PASSWORD=my_password!234 37 | # ---------------------------------------------------------------------- 38 | # ACARS/VDML related parameters: 39 | ACARS_FREQUENCIES='130.450;130.825;130.850;131.525;131.550;131.725;131.825;131.850' 40 | ACARS_FEEDER_ID=XX-XXXX-ACARS 41 | VDLM_SDR_SERIAL="sdr-serial-number" 42 | VDLM_SDR_GAIN="sdr-gain" 43 | VDLM_FREQUENCIES='136.650;136.675;136.725;136.775;136.825;136.875;136.975' 44 | VDLM_FEEDER_ID=XX-XXXX-VDL 45 | # ---------------------------------------------------------------------- 46 | # AIS related parameters: 47 | # ShipFeeder receiver and webpage related parameters: 48 | RTLSDR_DEVICE_SERIAL=DEVICE-SERIAL 49 | RTLSDR_DEVICE_GAIN=xxx 50 | RTLSDR_DEVICE_PPM=xxx 51 | AISCATCHER_DECODER_AFC_WIDE=on 52 | AISCATCHER_CHANNELS=AB CD 53 | STATION_NAME=My Station Name 54 | # 55 | # keys and params for aggregators: 56 | # If you aren't feeding a specific aggregator, leave the value EMPTY or remove the parameter 57 | AIRFRAMES_STATION_ID=XX-XXXXXXX-AIS 58 | AISCATCHER_FEEDER_KEY=xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx 59 | AISHUB_UDP_PORT=xxxx 60 | APRSFI_FEEDER_KEY=xxxxxxx 61 | APRSFI_STATION_ID=MYCALL 62 | BOATBEACON_SHAREDATA=true 63 | HPRADAR_UDP_PORT=xxxx 64 | MARINETRAFFIC_UDP_PORT=xxxxx 65 | MYSHIPTRACKING_UDP_PORT=xxxxx 66 | RADARVIRTUEL_FEEDER_KEY=xxxxxxxxx 67 | RADARVIRTUEL_STATION_ID=xx 68 | SHIPFINDER_SHAREDATA=true 69 | SHIPPINGEXPLORER_UDP_PORT=xxxxx 70 | SHIPXPLORER_SHARING_KEY=xxxxxxxxxxxxxxxxxxx 71 | SHIPXPLORER_SERIAL_NUMBER=SXTRPI00xxxx 72 | VESSELFINDER_UDP_PORT=xxxx 73 | VESSELTRACKER_UDP_PORT=xxxx 74 | VESSELALERT_MASTODON_TOKEN=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx 75 | VESSELALERT_MASTODON_CUSTOM_FIELD=Created with VesselAlert by kx1t - https://vesselalert.com 76 | VESSELALERT_DISCORD_NAME=Station_name near xxxxx harbor 77 | VESSELALERT_AVATAR_URL=https://link.to/my_avatar.jpg 78 | VESSELALERT_DISCORD_WEBHOOKS=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx,xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx 79 | --------------------------------------------------------------------------------