|sungo efc4e4fbc6 docker fu||10 months ago|
|.gitignore||10 months ago|
|Dockerfile||10 months ago|
|Gopkg.lock||10 months ago|
|Gopkg.toml||10 months ago|
|LICENSE.txt||10 months ago|
|Makefile||10 months ago|
|README.md||10 months ago|
|main.go||10 months ago|
|runner.sh||10 months ago|
sbshttp provides an HTTP server that presents dump1090 data in the "standard" JSON format.
The most supported fork of dump1090, the FlightAware version, removed the in-memory http server. dump1090-fa can output the standard real-time CSV feeds or static JSON files every second to disk. Most UIs use the JSON files so setting up a dump1090 environment involves burning IOPs for no real reason.
My use case is docker. I wanted an in-memory only solution that I could spin up without volumes or tmpsfs or other disk drama. There are old forks of dump1090 that retain the http server but do not pull in the fixes and improvements that the FlightAware folks are adding.
So here's this thing. It listens to dump1090's CSV feed and provides their JSON format. The JSON is always up to date with the most current data, with no 1 second lag. Throw up a UI, point it at this like you would dump1090-fa, and you should be ready to go.
All forks of dump1090 carry with them a README about the JSON output. For instance: https://github.com/flightaware/dump1090/blob/master/README-json.md
It turns out that, universally, this document is a lie. For example, dump1090-fa's UI is looking for this field list: https://github.com/flightaware/dump1090/blob/master/public_html/planeObject.js#L446
Mictronics/dump1090 is looking for https://github.com/Mictronics/dump1090/blob/master/public_html/planeObject.js#L429
FlightAware and Mictronics have both changed and extended the JSON format is different ways and failed to update the documentation. Universally, across dump1090 forks, this is true.
Extra fun: it looks like everyone left the CSV output alone, which this app relies on, but are writing new and interesting data into their JSON files. So, even when I map fields correctly, they may not be what your favorite UI expects.
In short: this is a complete shitshow and I can't support everything.
I'll be targetting UIs that I think are interesting and I want to use while trying to maintain compatibility with that common README that everyone is failing to update.
This is a personal side project and will get about that much attention, maybe less. If you have patches, feel free to contact me (see https://sungo.wtf) but I make no promise as to when or if I'll respond. But, feel free to fork the code, respecting the license, and have your way with it.
Copyright Matt Cashner (sungo)
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.