Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Better UI integration with FlightRadar24 in addition to FlightAware #44

Closed
e2jk opened this issue Feb 28, 2021 · 9 comments · Fixed by #45 or #49
Closed

Better UI integration with FlightRadar24 in addition to FlightAware #44

e2jk opened this issue Feb 28, 2021 · 9 comments · Fixed by #45 or #49

Comments

@e2jk
Copy link
Contributor

e2jk commented Feb 28, 2021

Specifications

Expected Behavior

As this Docker image combines both PiAware and FR24feed, I'd expect the UI to provide not just links to FlightAware but also to FlightRadar24, and a link to the local FR24Feed page, typically http://localhost:8754/
And why not, also a link to the public pages of one's own user/tracker on both platforms so that you can easily check the health of your radar, as seen externally by those 2 tracking sites:

Actual Behavior

Data upload is performed to both platforms, which is great.
But the UI elements are only FlightAware-focused

  • Logos (which I don't really care about), FlightAware and PiAware/SkyAware
  • Page title ("FlightAware SkyView")
  • Links to the flights pages, both clicking on the flight number link or the "Visit Flight Page" button when a flight is selected:

Capture d’écran de 2021-02-28 10-53-14

I don't expect FlightAware to modify their version of the dump1090 package to include links to one of their competitors, though ;)
What would be the most efficient way to get these changes, would we need to fork after each stable release and add these items/ Probably better than to try to monkey-patch directly from the Dockerfile...
Any interest to work (together) on this effort? I could create a new repo that downloads the latest stable release of flightaware/dump1090 and modifies/adds these elements, would that be something you'd be interested in?

The links to the user/tracker page on both platforms could be passed on as environment variables when launching the Docker container, like is done for all the other parameters of this container.

Note: I am not professionally affiliated to any of the 2 platforms in any way, just a simple user.
I have been a FR24 user for a long time (started my first receiver in 2013, pushing only to FR24) and just recently created my FlightAware profile and pushing to FA thanks to this repo. If it hadn't been for the easy integration with the 2 platforms that is facilitated by your Docker container @Thom-x, I would likely only have continued to push data to FR24 and not FlightAware.
Just adding this in case my suggestion here would be misinterpreted ("all this hard maintenance work done by FlightAware, and this guy just wants to tag along FR24"), it is thanks to this combination that I'm now also feeding FlightAware...

Steps to Reproduce the Problem

Regular install of the Docker image.

@Thom-x
Copy link
Owner

Thom-x commented Feb 28, 2021

It could be a good idea ! I don't really have time to do that but I would be happy to accept PR for it (and review them).

I'm not a front end expert, but I could help on the Docker part. 👍

@e2jk
Copy link
Contributor Author

e2jk commented Feb 28, 2021

Yes, time is an issue ;) I'm putting this on my todo list.

@Thom-x
Copy link
Owner

Thom-x commented Feb 28, 2021

Thank you !

e2jk added a commit to e2jk/docker-fr24feed-piaware-dump1090 that referenced this issue Feb 28, 2021
- Creating of a script that downloads the specified release and patches 
it
- Add FR24 logo and link
- Hide PiAware logo
e2jk added a commit to e2jk/docker-fr24feed-piaware-dump1090 that referenced this issue Feb 28, 2021
@e2jk
Copy link
Contributor Author

e2jk commented Feb 28, 2021

Hi @Thom-x , I've set up an initial patching setup that adds the FR24 logo and uses a neutral page name. This is how it looks like until now:

Capture d’écran de 2021-02-28 20-09-37

Before I go too far down that road, could you give it a try and tell me if that is in line with what you'd expect?

I've added a bit of explanation on how to run the original script that creates the patch file, not sure if it helps.
Basically I created a .patch file that modifies 4 files from the upstream release, and that file gets plugged into the Dockerfile.

Note: The patch works fine for v3.8.1 (the current target of "latest"), but fails on v4.0 because upstream added extra whitespace in the public_html/script.js file, in the updatePiAwareOrFlightFeeder() function that gets patched. Simple to update when v4.0 (or likely 4.1) is ready for usage.

@e2jk
Copy link
Contributor Author

e2jk commented Feb 28, 2021

Just to add a bit more context:

  • The "real" work happens here in the Dockerfile, in which:
    • The FR24 logo gets copied
    • The patch/flightradar24.patch file gets applied that modifies the index page to add the logo and the js files for a neutral page name

@Thom-x
Copy link
Owner

Thom-x commented Mar 1, 2021

Great ! You can do a PR and we will create a new docker tag to test if it's OK.

@e2jk
Copy link
Contributor Author

e2jk commented Mar 2, 2021

PR created with the code until now. I'm running a Raspi 1B, when creating/publishing the new Docker tag can you make sure to upload also the arm version? Thanks.

@Thom-x Thom-x closed this as completed in #45 Mar 7, 2021
Thom-x added a commit that referenced this issue Mar 7, 2021
…ghtAware (#45)

* Initial patch to include FR24 elements (#44)
- Creating of a script that downloads the specified release and patches 
it
- Add FR24 logo and link
- Hide PiAware logo

* Update paths to be ran from the `patch` folder

* Neutral page title (#44)

* Remove unneeded newlines in patch file

* Move the extracted upstream files one level up
So as to not keep the version number in the path

* Script output conditional on success of `patch` command

* Pass --force to `patch` to not have user prompts
Better to fail if anything is unclear or wrong, the error message will 
be displayed.

* Neutral page title, since the config.js file gets overwritten when building the container
Follow-up to eb85898

* chore: update css for fr24 header logo

Co-authored-by: MAUGIN Thomas <Thom-x@users.noreply.github.com>
@e2jk
Copy link
Contributor Author

e2jk commented Mar 7, 2021

Thanks for merging #45. Since there are more changes coming up in #49, @Thom-x can you reopen this issue and link the new PR to this issue too?

@e2jk
Copy link
Contributor Author

e2jk commented Mar 16, 2021

Great, thanks for merging both PRs!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants