feat(docs): Add documentation on how to install tables
continuous-integration/woodpecker the build failed Details

This commit is contained in:
Ferdinand Thiessen 2021-12-20 00:53:49 +01:00
parent 3935f9386b
commit 88718676f8
1 changed files with 20 additions and 16 deletions

View File

@ -33,7 +33,26 @@ Same as above, but if you want to use `mysqlclient` instead of `PyMySQL` (perfor
https://www.radishlogic.com/coding/python-3/installing-mysqldb-for-python-3-in-windows/
### Configuration
### Install database
The user needs to have full permissions to the database.
If not you need to create user and database manually do (or similar on Windows):
(
echo "CREATE DATABASE flaschengeist;"
echo "CREATE USER 'flaschengeist'@'localhost' IDENTIFIED BY 'flaschengeist';"
echo "GRANT ALL PRIVILEGES ON flaschengeist.* TO 'flaschengeist'@'localhost';"
echo "FLUSH PRIVILEGES;"
) | sudo mysql
Then you can install the database tables
$ flaschengeist db upgrade heads
Or to only upgrade one plugin:
$ flaschengeist db upgrade events@head
## Configuration
Configuration is done within the a `flaschengeist.toml`file, you can copy the one located inside the module path
(where flaschegeist is installed) or create an empty one and place it inside either:
1. `~/.config/`
@ -54,21 +73,6 @@ So you have to configure one of the following options to call flaschengeists CRO
- Pros: Guaranteed execution interval, no impact on user experience (at least if you do not limit wsgi worker threads)
- Cons: Uses one of the webserver threads while executing
### Database installation
The user needs to have full permissions to the database.
If not you need to create user and database manually do (or similar on Windows):
(
echo "CREATE DATABASE flaschengeist;"
echo "CREATE USER 'flaschengeist'@'localhost' IDENTIFIED BY 'flaschengeist';"
echo "GRANT ALL PRIVILEGES ON flaschengeist.* TO 'flaschengeist'@'localhost';"
echo "FLUSH PRIVILEGES;"
) | sudo mysql
Then you can install the database tables and initial entries:
$ flaschengeist install
### Run
$ flaschengeist run
or with debug messages: