This utility enables sending Mastodon posts of new events. Ever since Twitter started to restrict posting about locations of aircraft, are encouraging people to post to Mastodon,
There are two major parts to install this. Each of these parts is described below.
- You must have a Mastodon account and create an Application in it.
- You must follow the instructions below to configure PlaneFence to use the credentials that Mastodon provides you during this sign-up process.
This is part of the [sdr-enthusiasts/docker-planefence] docker container. Nothing in this document will make sense outside the context of this container.
Mastodon is a distributed social media service. This means, that you have your choice of Mastodon servers to create and maintain your account on. Any of them will work (as long as they allow bots), but we recommend joining this one. It's the one where many of us post results of our SDR and radio reception endeavors: https://airwaves.social/
Once you have an account, please do the following:
-
Sign in to Mastodon and go to the home page, for example: https://airwaves.social/home
-
Create a new Application by clicking the button, then:
- Give it a name (for example, "Planefence")
- Add a URL (if you don't have one, use something like "https://airwaves.social/@myhandle" (replace
myhandle
by your Mastodon handle)) - Make sure that the following scopes are selected (important!!!):
read
,write
,follow
- Press
Submit
at the bottom of the page
-
Open the Application and (important!!!) note the Access Token
Note -- the MASTODON_RETENTION_TIME
parameter in planefence.config
determines the retention time (in days) of any Toots you send to Mastodon. This will help manage storage costs for the operator of the Mastodon server! Note - the default expiration time if the parameter is omitted, is 7
(days). If you want your Toots to never expire, please set the parameter value to off
or 0
. However, please be cognizant that your Mastodon Server operator is probably paying for disk storage out of their own pocket - so please leave this retention time as short as you can afford.
Please set the following parameters in your planefence.config
file:
MASTODON_SERVER=airwaves.social
MASTODON_ACCESS_TOKEN=vsafdwafewarewdcvdsafwaefaewfdw
PF_MASTODON=ON
PA_MASTODON=ON
PA_MASTODON_VISIBILITY=unlisted
PF_MASTODON_VISIBILITY=unlisted
MASTODON_RETENTION_TIME=7
- Replace the values with the applicable server name and access token.
- If
PF_MASTODON
is not set toON
, then no PlaneFence Mastodon notifications will be sent. - If
PA_MASTODON
is not set toON
, then no Plane-Alert Mastodon notifications will be sent. Px_MASTODON_VISIBILITY
can bepublic
(visible in everyone's feed),unlisted
(only visible on your profile page), orprivate
(invisible to anyone except for you).
If you add a link to your public Planefence or Plane-Alert page in the Extra Fields section of your Public Profile on Mastodon, you will get automatic account verification (with a cool green checkmark) for your Mastodon account. Your Planefence and Plane-Alert pages will automatically add a hidden verification link with the rel="me"
element as described in the "Verification" tab of your Mastodon Profile Edit page.
- If verification fails, please ensure that your Planefence and Plane-Alert webpages are reachable when you press "Save my profile" in Mastodon. This will kick off a new verification attempt.
- Another thing to check is that your reverse web proxy (if you use one) isn't too aggressive blocking Bots. Specifically, User Agents that start with
http.rb
should be allowed to pass. Here are a few examples of verification attempts (from the webproxy'saccess.log
):
66.94.123.74 - - [03/Feb/2024:21:00:24 -0500] "GET /planefence/ HTTP/1.1" 200 27716 "-" "http.rb/5.1.1 (Mastodon/4.2.1; +https://airwaves.social/)"
66.94.123.74 - - [03/Feb/2024:21:00:25 -0500] "GET /plane-alert/ HTTP/1.1" 200 524687 "-" "http.rb/5.1.1 (Mastodon/4.2.1; +https://airwave.social/)"
This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program. If not, see https://www.gnu.org/licenses/.