|
7 months ago | |
---|---|---|
static | 4 years ago | |
views | 4 years ago | |
.gitignore | 4 years ago | |
COPYING | 4 years ago | |
README.md | 7 months ago | |
app.py | 4 years ago | |
models.py | 4 years ago | |
requirements.txt | 4 years ago | |
run.sh | 4 years ago | |
update_db.py | 4 years ago |
README.md
Let's keep the fediverse healthy!
The fediverse is diverse by nature. Anyone can put a node on the Internet. That means there will be content you agree with, and content you don't agree with.
If you want some help maintaining your node healthy, keep reading!
What does FediHealth do?
This software can help you define federation policies for your node.
It does this by suggesting node configuration to you, based on the policies defined by the other (friendly) nodes you list in a text file.
FediHealth collects and saves the federation policies from the list of nodes you define, and then starts a web server.
When you navigate to http://localhost:8080 you can:
- List the nodes you defined.
- List the sum of banned and/or followed nodes.
- List current and suggested policies for each node.
- Read the config that was collected from each node.
- See errors returned when querying the nodes' api.
Installation
Clone the project on your computer, create and configure a Python virtual environment.
git clone https://farga.exo.cat/buttle/fedihealth.git
cd fedihealth
python3 -m venv ./venv
source ./venv/bin/activate
pip install -r requirements.txt
Content policy configuration
Some nodes are healthy, some nodes are not. Make a list of the nodes whos' federation policies you trust.
Create and edit fedihealth/trusted_nodes.txt
Add one domain per line. eg:
# Lines beginning with '#' and empty lines are ignored.
my_node_domain.net
pleroma.cat
pleroma.libretux.com
santsenques.cat
peertube.example.com
some_other_node.org
Don't forget to include your node domain too!
Running the server
Execute fedihealth/run.sh
This will create the database if needed, and start the WSGIRefServer web server.
Open a browser and navigate to http://localhost:8080
Upgrading this software
To get the latest version of FediHealth, pull the code and install requirements.
cd fedihealth
git pull
source ./venv/bin/activate
pip install -r requirements.txt
If you see database errors, that means we've changed the schema.
Simply delete fedihealth/fedihealth.db
and execute fedihealth/run.sh
again.
Adding/removing nodes from the database
Edit trusted_nodes.txt
and execute fedihealth/run.sh
You will be prompted to update the database.
Node compatibility
FediHealth can read these federation policies from:
- Peertube:
Follows
- Pleroma:
Bans
Under construction:
- Funkwhale: (coming soon)
- GNU Social: (ASAP)
- Mastodon: (we're on it)
- Pixelfed: (on the radar)
Here are some things to keep in mind..
Pleroma
Pleroma's has many content filtering options.
We only base suggestions on ['mrf_simple']['reject']
. See the other options on the node's config page.
Peertube
Instances follows ensure visibility of your videos on other instances, and visibility of their videos on your instance. FediHealth will suggested instances you might want to follow.
Authentification
Authentification is not required for nodes running:
- Pleroma
- Peertube
Authentification is required for:
- Mastodon (not working yet)
Configuring Access tokens
- Create a user account on the node you want to access.
- Login and create an access token.
- Copy the token and paste it into
trusted_nodes.txt
Syntax
trusted_nodes.txt
contains a list of domain names. You associate a token with a domain by appending the token to the same line, seperated by :
node_domain_name.com
:
access_token
Updating tokens
After adding, modifying or deleting tokens from trusted_nodes.txt
, execute fedihealth/run.sh
to apply changes.
Errors
When you execute fedihealth/run.sh
we first try to determine the software running on each node listed in trusted_nodes.txt and then add that to the database.
Failed to add to the database. Possible causes are:
- The domain does not exist.
- The node does not respond.
- The node does not support https.
- FediHealth is not compatible with the node software.
After the node is successfully added to the database, we query it's federation policies. Possible errors are:
- Can't find the access token. Check
trusted_nodes.txt
- The access token is invalid. There is an authentification problem.
- This action is outside the authorized scopes. You don't have permission.
- (to be continued)