matthew game
- Python 87%
- HTML 13%
| Filename | Latest commit message | Latest commit date |
|---|---|---|
| .gitignore | ||
| app.py | ||
| bio.html | ||
| config.json | ||
| matthew-game.service | ||
| README.md | ||
matthew game
a simple game where you retrieve pieces of matthew
setup
before setting this up, you must have a functioning matrix server to handle federation keys. this only handles a profile.
-
clone this repository and enter it
-
make a python virtual environment and install the dependencies
python3 -m venv venv
source venv/bin/activate
pip install waitress flask
-
configure it if you want, i left a default config in
config.json.bio.htmlcan be used to customise the user bio. -
run the server with
waitress-serve --listen=127.0.0.1:8080 app:app. if you're on systemd, seematthew-game.servicefor an example unit. -
reverse proxy
/_matrix/federation/v1/query/profileto the game:
location /_matrix/federation/v1/query/profile {
proxy_pass http://127.0.0.1:8080;
}
it may be possible to limit the user like so:
location /_matrix/federation/v1/query/profile?user_id=@target:example.com {
proxy_pass http://127.0.0.1:8080;
}
but i haven't tried this.
todo:
- a script to upload and manage the tiles
- go rewrite