mirror of
https://github.com/Casvt/MIND.git
synced 2026-02-19 11:54:46 -05:00
Doc update (#67)
* Updated README * Added EXPOSE to Dockerfile for Docker Desktop * Refactored docker compose file * Updated CONTRIBUTING * Docs update * Added docs for sending files * Added styling of scroll bar * Fixed various colors * Fixed Dockerfile exposed port * Updated api docs for merging * Attempt at fixing merge problems
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
# Contributing to MIND
|
||||
## General steps
|
||||
Contributing to MIND consists of 5 steps:
|
||||
Contributing to MIND consists of 5 steps, listed hereunder.
|
||||
|
||||
1. Make a [contributing request](https://github.com/Casvt/MIND/issues/new?template=contribute-request.md), where you describe what you plan on doing. This request needs to get approved before you can start, or your pull request won't be accepted. This is to avoid multiple people from doing the same thing and to avoid you wasting your time if we do not wish the changes. This is also where discussions can be held about how something will be implemented.
|
||||
2. When the request is accepted, start your local development (more info about this below).
|
||||
@@ -11,25 +11,23 @@ Contributing to MIND consists of 5 steps:
|
||||
## Local development steps
|
||||
Once your request is accepted, you can start your local development.
|
||||
|
||||
1. Fork the repository and clone the fork onto your computer and open it using your preferred IDE (Visual Studio Code is used by us).
|
||||
2. Make the changes needed and write accompanying tests.
|
||||
1. Clone the repository onto your computer and open it using your preferred IDE (Visual Studio Code is used by us).
|
||||
2. Make the changes needed and write accompanying tests if needed.
|
||||
3. Check if the code written follows the styling guide below.
|
||||
4. If you want to run the tests manually before committing, use the command below in the root folder of the project:
|
||||
4. Run the finished version, using python 3.8, to check if you've made any errors.
|
||||
5. Run the tests (unittest is used). This can be done with a button click within VS Code, or with the following command where you need to be inside the root folder of the project:
|
||||
```bash
|
||||
python3 -m unittest discover -v -s './tests' -p '*_test.py'
|
||||
python3 -m unittest discover -s ./tests -p '*.py'
|
||||
```
|
||||
5. Update the docs if needed.
|
||||
6. Commit and push to your fork. When you push, GitHub Actions will do a lot of work for you: the tests are run again on python versions 3.8 - 3.11, the API documentation is updated if any changes have been made to the API and the docs are updated if any changes have been made to the docs. All GitHub Actions need to succeed before you're allowed to make a PR (you'll see a green checkmark next to the commit in GitHub).
|
||||
6. Test your version thoroughly to catch as many bugs as possible (if any).
|
||||
|
||||
## Styling guide
|
||||
The code of MIND is written in such way that it follows the following rules. Your code should too.
|
||||
|
||||
1. Compatible with python 3.8 .
|
||||
1. Compatible with python 3.8 to 3.11 .
|
||||
2. Tabs (4 space size) are used for indentation.
|
||||
3. Use type hints as much as possible, though don't if it requires importing extra functions or classes (except for the `typing` library).
|
||||
3. Use type hints as much as possible. If you encounter an import loop because something needs to be imported for type hinting, utilise [`typing.TYPE_CHECKING`](https://docs.python.org/3/library/typing.html#typing.TYPE_CHECKING).
|
||||
4. Each function in the backend needs a doc string describing the function, what the inputs are, what errors could be raised from within the function and what the output is.
|
||||
5. The imports need to be sorted (the extension `isort` is used in VS Code).
|
||||
6. The code needs to be compatible with Linux, MacOS, Windows and Docker.
|
||||
6. The code needs to be compatible with Linux, MacOS, Windows and the Docker container.
|
||||
7. The code should, though not strictly enforced, reasonably comply with the rule of 80 characters per line.
|
||||
|
||||
If you just code in the same style as the current code, you'll follow most of these rules automatically.
|
||||
|
||||
@@ -10,4 +10,6 @@ RUN pip3 install -r requirements.txt
|
||||
|
||||
COPY . .
|
||||
|
||||
EXPOSE 8080
|
||||
|
||||
CMD [ "python3", "/app/MIND.py" ]
|
||||
|
||||
43
README.md
43
README.md
@@ -1,40 +1,45 @@
|
||||
# MIND
|
||||
|
||||
[](https://hub.docker.com/r/mrcas/mind)
|
||||
[](https://github.com/Casvt/MIND/releases)
|
||||
|
||||
__A simple self hosted reminder application that can send push notifications to your device. Set the reminder and forget about it!__
|
||||
|
||||
Mind is a simple self hosted application for creating reminders that get pushed to your device using the [Apprise](https://github.com/caronc/apprise) API. You can send messages to just about every platform, including scheduled emails!
|
||||
|
||||
## Workings
|
||||
MIND can be used for sending notifications at the desired time. This can be a set time, like a yearly reminder for a birthday, or at a button click, to easily send a predefined notification when you want to.
|
||||
|
||||
MIND can be used for sending notifications at the desired time. This can be a set time, like a yearly reminder for a birthday, or at a button click, to easily send a predefined notification when you want to. The notification can be sent to 80+ platforms with the integration of [Apprise](https://github.com/caronc/apprise).
|
||||
|
||||
## Features
|
||||
|
||||
- Works cross-timezone
|
||||
|
||||
- Notifications are sent with second-precision
|
||||
- Uses the [apprise library](https://github.com/caronc/apprise), giving you 80+ platforms to send notifications to
|
||||
|
||||
- Fine control over repetition: single time, time interval, certain weekdays or manual trigger.
|
||||
|
||||
- Uses the [Apprise library](https://github.com/caronc/apprise), giving you 80+ platforms to send notifications to and the option to send to multiple platforms for each reminder
|
||||
|
||||
- Easily manage the reminders with sorting options, search ability and color coding
|
||||
|
||||
- An admin panel for user management, settings and backups
|
||||
|
||||
- Docker image available
|
||||
|
||||
- Mobile friendly web-interface
|
||||
|
||||
- API available
|
||||
|
||||
### Planned Features
|
||||
You can see the planned features in the [Project board](https://github.com/users/Casvt/projects/3).
|
||||
## Installation, support and documentation
|
||||
|
||||
## Getting started
|
||||
Replace the timezone value (`TZ=`) to the [TZ database name](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones) of your timezone!
|
||||
```bash
|
||||
docker run -d \
|
||||
--name mind \
|
||||
-v mind-db:/app/db \
|
||||
-e TZ=Europe/Amsterdam \
|
||||
-p 8080:8080 \
|
||||
mrcas/mind:latest
|
||||
```
|
||||
- For instructions on how to install MIND, see the [installation documentation](https://casvt.github.io/MIND/installation/installation)
|
||||
|
||||
More information about installing can be found [in the wiki](https://casvt.github.io/MIND/).
|
||||
- For support, a [discord server](https://discord.gg/nMNdgG7vsE) is available or [make an issue](https://github.com/Casvt/MIND/issues)
|
||||
|
||||
## Contact
|
||||
- For support, a [discord server](https://discord.gg/nMNdgG7vsE) is available
|
||||
- Alternatively, [make an issue](https://github.com/Casvt/MIND/issues)
|
||||
- For all documentation, see the [documentation hub](https://casvt.github.io/MIND).
|
||||
|
||||
## Screenshots
|
||||
|
||||
<img src="https://github.com/Casvt/Kapowarr/assets/88994465/f55c895b-7975-4a3e-88a0-f8e2a148bf8a" style="width: max(45%, 400px); margin: .5rem;">
|
||||
<img src="https://github.com/Casvt/Kapowarr/assets/88994465/63d72943-0c88-4315-9a8a-01a5dc5f6f15" style="width: max(45%, 400px); margin: .5rem;">
|
||||
<img src="https://github.com/Casvt/Kapowarr/assets/88994465/1f9cc9a2-ced5-49a2-b779-93528bb50bd4" style="width: max(45%, 400px); margin: .5rem;">
|
||||
|
||||
@@ -1,11 +1,14 @@
|
||||
version: '3.3'
|
||||
version: "3.3"
|
||||
services:
|
||||
mind:
|
||||
container_name: mind
|
||||
image: mrcas/mind:latest
|
||||
volumes:
|
||||
- 'mind-db:/app/db'
|
||||
- "mind-db:/app/db"
|
||||
environment:
|
||||
- TZ=Europe/Amsterdam
|
||||
ports:
|
||||
- '8080:8080'
|
||||
image: 'mrcas/mind:latest'
|
||||
- 8080:8080
|
||||
|
||||
volumes:
|
||||
mind-db:
|
||||
@@ -878,5 +878,4 @@ Replace `<int:u_id>` with the ID of the entry. For example: `/admin/users/2`.
|
||||
| 201 | N/A | Success |
|
||||
| 400 | InvalidDatabaseFile | The uploaded database file is invalid or not supported |
|
||||
| 400 | InvalidKeyValue | The value of a key is invalid |
|
||||
| 400 | KeyNotFound | A key was not found in the input that is required to be given |
|
||||
|
||||
| 400 | KeyNotFound | A key was not found in the input that is required to be given |
|
||||
@@ -5,6 +5,21 @@
|
||||
--color-dark: #1b1b1b;
|
||||
}
|
||||
|
||||
::-webkit-scrollbar {
|
||||
width: 12px;
|
||||
height: 12px;
|
||||
background-color: var(--color-gray);
|
||||
}
|
||||
|
||||
::-webkit-scrollbar-thumb {
|
||||
-webkit-border-radius: 6px;
|
||||
background-color: var(--color-dim-light);
|
||||
}
|
||||
|
||||
::-webkit-scrollbar-thumb:hover {
|
||||
background-color: var(--color-light);
|
||||
}
|
||||
|
||||
.md-typeset code {
|
||||
border-radius: 6px;
|
||||
}
|
||||
@@ -54,6 +69,9 @@
|
||||
/* Hover color for mark and ToC */
|
||||
--md-accent-fg-color: var(--color-gray);
|
||||
|
||||
/* BG color git link in mobile nav */
|
||||
--md-primary-fg-color--dark: var(--color-gray);
|
||||
|
||||
/* Code color */
|
||||
--md-code-fg-color: var(--color-light);
|
||||
/* Code background color */
|
||||
@@ -117,8 +135,8 @@
|
||||
color: var(--color-gray);
|
||||
}
|
||||
|
||||
[data-md-color-scheme="MIND"] .tabbed-block {
|
||||
--md-default-fg-color--light: var(--color-dark);
|
||||
[data-md-color-scheme="MIND"] [data-md-component="sidebar"][data-md-type="navigation"] nav > label {
|
||||
background-color: var(--color-gray);
|
||||
}
|
||||
|
||||
[data-md-color-scheme="MIND"] details {
|
||||
@@ -158,6 +176,9 @@
|
||||
/* Hover color for mark and ToC */
|
||||
--md-accent-fg-color: var(--color-dim-light);
|
||||
|
||||
/* BG color git link in mobile nav */
|
||||
--md-primary-fg-color--dark: var(--color-gray);
|
||||
|
||||
/* Code color */
|
||||
--md-code-fg-color: var(--color-light);
|
||||
/* Code background color */
|
||||
@@ -217,8 +238,8 @@
|
||||
color: var(--color-dim-light);
|
||||
}
|
||||
|
||||
[data-md-color-scheme="MIND-dark"] .tabbed-block {
|
||||
--md-default-fg-color--light: var(--color-dark);
|
||||
[data-md-color-scheme="MIND-dark"] [data-md-component="sidebar"][data-md-type="navigation"] nav > label {
|
||||
background-color: var(--color-dim-light);
|
||||
}
|
||||
|
||||
[data-md-color-scheme="MIND-dark"] details {
|
||||
|
||||
@@ -1,23 +0,0 @@
|
||||
# Backup your data
|
||||
|
||||
It's possible, and very easy, to backup all MIND data. This way, you can recover data if something goes wrong, port your instance over to an other computer or run redundant instances.
|
||||
|
||||
## Backing up the data
|
||||
|
||||
It's as simple as making a copy of the database file and storing it somewhere safe.
|
||||
|
||||
1. Stop MIND, if it's still running.
|
||||
2. Go inside the docker volume of the container (most likely `mind-db`) or the mapped folder.
|
||||
3. Inside the volume/folder, you'll find the `MIND.db` file. Make a copy of this. That's all you need.
|
||||
4. You can now start the instance back up.
|
||||
|
||||
The database file contains all data and is the only thing needed to keep a complete backup of your MIND instance.
|
||||
|
||||
## Recovering the data
|
||||
|
||||
It's as simple as putting the database file in the database folder and restarting the instance.
|
||||
|
||||
1. Stop MIND, if it's still running.
|
||||
2. Go inside the docker volume of the container (most likely `mind-db`) or the mapped folder.
|
||||
3. Inside the volume/folder, place the database file that you backed up.
|
||||
4. You can now start the instance back up. Everything should be recovered.
|
||||
54
docs/general_info/admin_panel.md
Normal file
54
docs/general_info/admin_panel.md
Normal file
@@ -0,0 +1,54 @@
|
||||
## Introduction
|
||||
|
||||
The admin panel allows you to manage your MIND instance. It has multiple features regarding the management of your instance and it's users. You can change how users authenticate and create accounts, download the logs, change the hosting settings, add/edit/delete users, export and import the database and restart or shutdown the application.
|
||||
|
||||
!!! warning "Restrict Access"
|
||||
The panel gives you a lot of power, so it's important that nobody can access it but you (by changing the default password).
|
||||
|
||||
### Accessing the panel
|
||||
|
||||
You can access the admin panel by logging into the admin account. The default username is `admin` and the default password is `admin`. How to change the password (which is strongly recommended) is described in the ['User Management' section](#user-management).
|
||||
|
||||
## Authentication
|
||||
|
||||
The authentication settings are described on the ['Admin Settings' page](../settings/admin_settings.md#authentication).
|
||||
|
||||
## Logging
|
||||
|
||||
The 'Logging Level' setting is for enabling debug logging. Only enable this when you encounter problems and need to share logs. Once enabled, all debug logs will go to a file. This file, containing all the debug logs, can be downloaded using the 'Download Debug Logs' button. Once the logging level is set back to `Info`, the debug logging to the file will be stopped. Once the logging level is set to `Debug` again, the file will be emptied and all debug logs will be put in it again. With this setup, you can enable debug logging, reproduce the error (which will be logged to the file), disable debug logging and download the log file. The file will then contain all relevant logs.
|
||||
|
||||
## Hosting
|
||||
|
||||
The hosting settings are described on the ['Admin Settings' page](../settings/admin_settings.md#hosting).
|
||||
|
||||
## User Management
|
||||
|
||||
The admin panel allows you to manage the users on your instance. You can add new users, change the password of existing users and delete users. The ability to add users will always be there, regardless of the value of the ['Allow New Accounts' setting](../settings/admin_settings.md#allow-new-accounts). If that setting is disabled (disallowing users to create accounts themselves), then the admin panel is the only place where new accounts can be made.
|
||||
|
||||
If the username field turns red while adding a new user, then the username is either already taken or is invalid.
|
||||
|
||||
Click on the pen icon to change the password of the user. This is useful if the user has forgotten their password. You can also change the password of the admin user this way, which is strongly recommended.
|
||||
|
||||
## Database
|
||||
|
||||
The 'Download Database' button allows you to download the complete MIND database. This file contains everything: all user accounts, their settings, notification services and reminders, and admin settings (authentication, hosting, etc.). This file represents a complete back-up of your MIND instance.
|
||||
|
||||
The admin panel offers the option to upload a database file to apply. There are multiple scenarios where you'd want to upload a database (import a backup):
|
||||
|
||||
1. You can recover all data up to the point of database export in the case that something goes wrong.
|
||||
2. You can revert back to a stable state when trying something.
|
||||
3. You're moving to a new computer/instance and want to move all user data too.
|
||||
|
||||
Select the database file that you want to import for the 'Database File' input. Enabling the 'Keep Hosting Settings' option will copy the hosting settings from the current database over to the imported database. This will result in the instance being hosted with the same settings as it is now. If you leave this setting disabled, the hosting settings from the imported database will be used. That could result in the web-UI being hosted with different settings, potentially making it unreachable.
|
||||
|
||||
The uploaded file could be denied for multiple reasons:
|
||||
|
||||
1. It is not an (sqlite) database file. Only import database files that you downloaded with the 'Download Database' button.
|
||||
2. The database file is too old. If the database is for such an old version of MIND, it could fail to migrate it.
|
||||
3. The database file is too new. If the database is for a newer version of MIND than the version that you upload it to, it get's denied.
|
||||
|
||||
After importing the database, MIND will restart with the new database in use. **_It is required to log into the admin panel within one minute in order to keep the newly imported database file. If you do not, the import will be reverted, MIND will restart again but now with the old database again._** This is in order to protect you from breaking MIND if the database file is invalid or if the hosting settings make the UI unreachable (if you have the 'Keep Hosting Settings' option disabled).
|
||||
|
||||
## Power
|
||||
|
||||
You can use these buttons to restart or shutdown the application.
|
||||
43
docs/general_info/reminders.md
Normal file
43
docs/general_info/reminders.md
Normal file
@@ -0,0 +1,43 @@
|
||||
## Introduction
|
||||
|
||||
On this page you can find more information on the type of reminders, how to add them, how to manage them and some implementation details. It is assumed that you already have [set up your notification services](../installation/setup_after_installation.md#add-a-notification-service).
|
||||
|
||||
## Types of Reminders
|
||||
|
||||
There are two types of reminders: time dependent reminders ('normal reminders') and time independent reminders ('static reminders'). Then there are also 'templates', which you can use to create normal and static reminders faster.
|
||||
|
||||
### Normal Reminders
|
||||
|
||||
Normal reminders require a time that they need to be triggered on. Once they are triggered, they are deleted (unless they repeat). In the UI, select the tab 'Reminders' and click the '+' button to add a new reminder.
|
||||
|
||||
1. You can select a template to build upon. More info on that in the ['Templates' section](#templates).
|
||||
2. If desired, you can select a colour that the reminder will get in the list. [This image](https://github.com/Casvt/Kapowarr/assets/88994465/f55c895b-7975-4a3e-88a0-f8e2a148bf8a) displays coloured reminders in a library.
|
||||
3. Next is the title, which should be what you want to be reminded of. This is also shown in the library view.
|
||||
4. The time and date that is set will be the moment that the reminder will be sent.
|
||||
5. Click on 'Notification Services' to see the list of services that you've set up. Select at least one for the reminder to use when it's triggered. You can also select multiple. The ['Default Notification Service' setting](../settings/user_settings.md#default-notification-service) decides which service is selected by default.
|
||||
6. You can change the reminder to be repeated or not. More info on this below.
|
||||
7. The text field is where you can add extra info. This is _not_ shown in the library view, but _will_ be included in the notification that is sent (if supported, which it most likely is).
|
||||
8. Clicking the 'Test' button will send the reminder, so that you can check if it works as desired. Then click 'Add' to finalise the creation.
|
||||
|
||||
Once it's added, the timer is set! When the set time is reached, the reminder will be sent and will then disappear from your library.
|
||||
|
||||
#### Repeated Reminders
|
||||
|
||||
By default, normal reminders are 'single-use' and are deleted after they are triggered. However, it's also possible to repeat reminders either by time interval or week days.
|
||||
|
||||
For repetition by time interval, select 'Repeated' when creating a reminder and select the time interval (e.g. '5 days' or '1 year'). The first time the reminder will be sent is on the set time. The interval will then be added and the resulting time will be the next time the reminder will be triggered.
|
||||
|
||||
!!! info "Implementation detail: repetition on non-yearly days"
|
||||
If the reminder is set on a day that does not exist every interval (e.g. leap day each year, or the 31st each month) it will be triggered on the set day the first time, but from then on will trigger on the closest day within the same month and it will stay there. So if you set a reminder for 29-2-2024 (D-M-Y) and set the reminder to repeat each year, the next reminders will be triggered on 28-2-2025, 28-2-2026, 28-2-2027, 28-2-2028, etc. Notice that even in 2028, when there is a 29th day in February, it will still run on the 28th. This is because it ran on the 28th the previous year, so add one year to it and it will run on the 28th again.
|
||||
|
||||
Instead of repeating based on a certain time interval, it is also possible to repeat based on the week days. Select 'Week Days' when creating a reminder and select the days of the week that you want the reminder to trigger on. For example, if you select 'Mo' and 'Thu', the reminder will be triggered every Monday and Thursday. The time is based on the time set. The date of the time set decides when the reminder starts repeating.
|
||||
|
||||
### Static Reminders
|
||||
|
||||
Static reminders work the same way as normal reminders, except is there no time aspect. There is no date, time or repetition. This is because static reminders are only triggered manually. Simply click on the reminder in the library and click the 'Trigger' button to send the reminder.
|
||||
|
||||
The use of this is to notify people on command. For example, a notification to your kids that you'll be late. You don't want to send such a thing on a certain time or interval, but instead on command. Or an e-mail to your team notifying them of a emergency meeting. With static reminders, you can set it up once and when needed click one button to notify everyone withing seconds.
|
||||
|
||||
### Templates
|
||||
|
||||
Templates can be used to make it easier to create (static) reminders by filling in fields when selecting it. In the UI, select the 'Templates' tab and click the '+' button to add a template. Templates can store the colour, title, notification service selection and text (body) of the (static) reminder. When saved, you can start using it in the creation of (static) reminders. Simply select the template from the list and all the fields will be filled automatically. The only fields left are the time fields for normal reminders.
|
||||
9
docs/general_info/workings.md
Normal file
9
docs/general_info/workings.md
Normal file
@@ -0,0 +1,9 @@
|
||||
# Introduction
|
||||
|
||||
Here you can learn more about how to use MIND, how features work and certain implementation details.
|
||||
|
||||
[Reminders](./reminders.md)
|
||||
How to make and manage reminders.
|
||||
|
||||
[Admin Panel](./admin_panel.md)
|
||||
What is possible in the admin panel.
|
||||
@@ -1,38 +1,32 @@
|
||||
# MIND Docs
|
||||
|
||||
[](https://hub.docker.com/r/mrcas/mind)
|
||||
[](https://github.com/Casvt/MIND/releases)
|
||||
---
|
||||
description: The Official MIND Documentation Hub!
|
||||
hide:
|
||||
- navigation
|
||||
---
|
||||
# MIND Documentation Hub
|
||||
|
||||
__A simple self hosted reminder application that can send push notifications to your device. Set the reminder and forget about it!__
|
||||
|
||||
Getting started:
|
||||
MIND can be used for sending notifications at the desired time. This can be a set time, like a yearly reminder for a birthday, or at a button click, to easily send a predefined notification when you want to. The notification can be sent to 80+ platforms with the integration of [Apprise](https://github.com/caronc/apprise).
|
||||
|
||||
- [Installation](./installation.md)
|
||||
- [Setup After Installation](./setup_after_installation.md)
|
||||
## Quick Links
|
||||
|
||||
General Information:
|
||||
### Getting Started
|
||||
|
||||
- [API Docs](./api.md)
|
||||
- [Installation and Updating](./installation/installation.md)
|
||||
- [Setup after installation](./installation/setup_after_installation.md)
|
||||
|
||||
## Workings
|
||||
### General Information
|
||||
|
||||
MIND can be used for sending notifications at the desired time. This can be a set time, like a yearly reminder for a birthday, or at a button click, to easily send a predefined notification when you want to.
|
||||
- [How features work](./general_info/workings.md)
|
||||
- [API Documentation](./other_docs/api.md)
|
||||
|
||||
## Features
|
||||
### Settings
|
||||
|
||||
- Works cross-timezone
|
||||
- Notifications are sent with second-precision
|
||||
- Uses the [apprise library](https://github.com/caronc/apprise), giving you 80+ platforms to send notifications to
|
||||
- Easily manage the reminders with sorting options, search ability and color coding
|
||||
- Docker image available
|
||||
- Mobile friendly web-interface
|
||||
- API available
|
||||
|
||||
### Planned Features
|
||||
|
||||
You can see the planned features in the [Project board](https://github.com/users/Casvt/projects/3).
|
||||
- [Explanation of settings](./settings/settings.md)
|
||||
|
||||
## Contact
|
||||
|
||||
- For support, a [discord server](https://discord.gg/nMNdgG7vsE) is available
|
||||
- Alternatively, [make an issue](https://github.com/Casvt/MIND/issues)
|
||||
- For support, a [Discord server](https://discord.gg/nMNdgG7vsE) is available.
|
||||
- For issues or feature suggestions, see the [Reporting page](./other_docs/reporting.md).
|
||||
- For donations, go to [Ko-Fi](https://ko-fi.com/casvt).
|
||||
|
||||
@@ -1,97 +0,0 @@
|
||||
# Installation
|
||||
|
||||
The recommended way to install MIND is using Docker. After installing MIND, it is advised to read the [Setup After Installation page](setup_after_installation.md).
|
||||
|
||||
NOTE: Make sure to set all time related settings (time, date, timezone, etc.) correct on your computer, as MIND depends on it to work correctly.
|
||||
|
||||
## Docker
|
||||
|
||||
### Database location
|
||||
|
||||
We first need to create a named volume, or a folder, to store the database file of MIND in.
|
||||
|
||||
=== "Docker CLI"
|
||||
```bash
|
||||
docker volume create mind-db
|
||||
```
|
||||
|
||||
=== "Portainer"
|
||||
- Open `Volumes`
|
||||
- Click `Add Volume`
|
||||
- Enter name matching the one you'll use in compose (`mind-db`, in the above provided command)
|
||||
- Click `Create the volume`
|
||||
- Open `Stacks`
|
||||
- Create the stack with the named volume in it.
|
||||
|
||||
=== "Folder"
|
||||
Linux standards suggest to put the database in `/opt/application_name`, as the `/opt` directory is where program options should be stored. In this case, you'd create the desired folder using the following command:
|
||||
```bash
|
||||
mkdir /opt/MIND/db
|
||||
```
|
||||
|
||||
### Run the container
|
||||
|
||||
Now that we can store the database somewhere, we can get the container running.
|
||||
|
||||
=== "Docker CLI"
|
||||
The command to get the docker container running can be found below. Replace the timezone value (`TZ=`) with the [TZ database name](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones#List) of your timezone (value of `TZ identifier` on webpage).
|
||||
```bash
|
||||
docker run -d \
|
||||
--name mind \
|
||||
-v mind-db:/app/db \
|
||||
-e TZ=Europe/Amsterdam \
|
||||
-p 8080:8080 \
|
||||
mrcas/mind:latest
|
||||
```
|
||||
|
||||
=== "Docker Compose"
|
||||
The contents of the `docker-compose.yml` file would look like below. Replace the timezone value (`TZ=`) with the [TZ database name](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones#List) of your timezone (value of `TZ identifier` on webpage).
|
||||
```yml
|
||||
version: '3.3'
|
||||
services:
|
||||
mind:
|
||||
container_name: mind
|
||||
volumes:
|
||||
- 'mind-db:/app/db'
|
||||
environment:
|
||||
- TZ=Europe/Amsterdam
|
||||
ports:
|
||||
- '8080:8080'
|
||||
image: 'mrcas/mind:latest'
|
||||
```
|
||||
Now run the compose by running the following command in the root folder:
|
||||
```bash
|
||||
docker compose up -d
|
||||
```
|
||||
|
||||
If you didn't name your docker volume `mind-db` (see [Database location](#database-location)), replace `mind-db` in the command with the name of your volume. If you created a folder, replace `mind-db` with `/opt/MIND/db` or the folder you want.
|
||||
|
||||
Information on how to change the port can be found on the [Setup After Installation page](setup_after_installation.md#port).
|
||||
|
||||
## Manual Install
|
||||
|
||||
See below for installation instructions for your OS if you want to install it manually.
|
||||
|
||||
=== "Linux / MacOS"
|
||||
```bash
|
||||
sudo apt-get install git python3-pip
|
||||
sudo git clone https://github.com/Casvt/MIND.git /opt/MIND
|
||||
cd /opt/MIND
|
||||
python3 -m pip install -r requirements.txt
|
||||
python3 MIND.py
|
||||
```
|
||||
|
||||
=== "Windows"
|
||||
1. Install python [in the Microsoft Store](https://www.microsoft.com/store/productId/9PJPW5LDXLZ5)
|
||||
2. Install pip [using these instructions](https://www.liquidweb.com/kb/install-pip-windows/)
|
||||
3. Download [the latest release](https://github.com/Casvt/MIND/zipball/master)
|
||||
4. Extract the ZIP file
|
||||
5. With the folder open, right click and select `Open in Terminal`
|
||||
6. Type the following command:
|
||||
```bash
|
||||
python -m pip install -r requirements.txt
|
||||
```
|
||||
7. Type the following command:
|
||||
```bash
|
||||
python MIND.py
|
||||
```
|
||||
189
docs/installation/docker.md
Normal file
189
docs/installation/docker.md
Normal file
@@ -0,0 +1,189 @@
|
||||
On this page, you can find instructions on how to instal MIND using Docker and how to update a Docker installation.
|
||||
|
||||
## Installation
|
||||
|
||||
### Time settings
|
||||
|
||||
Make sure to set all time related settings (time, date, timezone, etc.) correct on your computer, as MIND depends on it to work correctly.
|
||||
|
||||
### Instal Docker
|
||||
|
||||
The first step is to instal Docker, if you don't have it installed already. The official Docker documentation hub offers great instructions on [how to instal docker CLI and Docker Desktop](https://docs.docker.com/engine/install/). Take notice of if you installed the 'Docker CLI' (the Docker documentation also calls this 'Docker CE') or if you installed 'Docker Desktop', for future instructions.
|
||||
|
||||
### Create Docker volume or folder
|
||||
|
||||
MIND needs a permanent place to put the database file, which contains all the user data and configs. This can be a [Docker volume](https://docs.docker.com/storage/volumes/), or a folder on the host machine.
|
||||
|
||||
=== "Docker Volume"
|
||||
=== "Docker CLI"
|
||||
|
||||
```bash
|
||||
docker volume create mind-db
|
||||
```
|
||||
|
||||
=== "Docker Compose"
|
||||
|
||||
```bash
|
||||
docker volume create mind-db
|
||||
```
|
||||
|
||||
=== "Docker Desktop"
|
||||
- Open `Volumes`
|
||||
- Click `Create`
|
||||
- Enter `mind-db` for the name and click `Create`
|
||||
|
||||
=== "Local Folder"
|
||||
=== "Linux"
|
||||
Linux standards would suggest putting the folder in `/opt/application_name`, as the `/opt` directory is where program options should be stored. This is not mandatory however; you are allowed to create a folder anywhere you like. If we apply the standard to MIND, the folder would be `/opt/MIND/db`.
|
||||
|
||||
Create the desired folder using the UI (if your distro offers this) or with the following shell command (replace `/path/to/directory` with desired path):
|
||||
|
||||
```bash
|
||||
mkdir "/path/to/directory"
|
||||
```
|
||||
|
||||
!!! info "Permissions and ownership"
|
||||
The permissions on this folder need to allow the container to read, write, and execute inside it. It also needs to have proper ownership. More documentation on this subject coming.
|
||||
|
||||
=== "MacOS"
|
||||
MacOS standards would suggest putting the folder in `/Applications/application_name`. This is not mandatory however; you are allowed to create a folder anywhere you like. If we apply the standard to MIND, the folder would be `/Applications/MIND/db`.
|
||||
|
||||
Create the desired folder using the UI or with the following shell command (replace `/path/to/directory` with desired path):
|
||||
|
||||
```bash
|
||||
mkdir "/path/to/directory"
|
||||
```
|
||||
|
||||
!!! info "Permissions and ownership"
|
||||
The permissions on this folder need to allow the container to read, write, and execute inside it. It also needs to have proper ownership. More documentation on this subject coming.
|
||||
|
||||
=== "Windows"
|
||||
There is no defined standard for Windows on where to put such a folder. We suggest a path like `C:\apps\application_name`, so that it can be managed easily. This is not mandatory however; you are allowed to create a folder anywhere you like. If we apply this suggestion to MIND, the folder would be `C:\apps\MIND\db`.
|
||||
|
||||
Create the desired folder either using the Windows Explorer, or using the following Powershell command:
|
||||
|
||||
```powershell
|
||||
mkdir "C:\apps\MIND\db"
|
||||
```
|
||||
|
||||
!!! info "Permissions and ownership"
|
||||
The permissions on this folder need to allow the container to read, write, and execute inside it. It also needs to have proper ownership. More documentation on this subject coming.
|
||||
|
||||
### Launch container
|
||||
|
||||
Now we can launch the container.
|
||||
|
||||
=== "Docker CLI"
|
||||
The command to get the Docker container running can be found below. But before you copy, paste and run it, read the notes below!
|
||||
|
||||
=== "Linux"
|
||||
|
||||
```bash
|
||||
docker run -d \
|
||||
--name mind \
|
||||
-v "mind-db:/app/db" \
|
||||
-e TZ=Europe/Amsterdam \
|
||||
-p 8080:8080 \
|
||||
mrcas/mind:latest
|
||||
```
|
||||
|
||||
=== "MacOS"
|
||||
|
||||
```bash
|
||||
docker run -d \
|
||||
--name mind \
|
||||
-v "mind-db:/app/db" \
|
||||
-e TZ=Europe/Amsterdam \
|
||||
-p 8080:8080 \
|
||||
mrcas/mind:latest
|
||||
```
|
||||
|
||||
=== "Windows"
|
||||
|
||||
```powershell
|
||||
docker run -d --name mind -v "mind-db:/app/db" -e TZ=Europe/Amsterdam -p 8080:8080 mrcas/mind:latest
|
||||
```
|
||||
|
||||
A few notes about this command:
|
||||
|
||||
1. If you're using a folder on the host machine instead of a docker volume to store the database file ([reference](#create-docker-volume-or-folder)), replace `mind-db` with the path to the host folder.
|
||||
E.g. `"/opt/MIND/db:/app/db"`.
|
||||
E.g. `"C:\apps\MIND\db:/app/db"`.
|
||||
|
||||
2. Replace the timezone value (`TZ=`) with the [TZ database name](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones#List) of your timezone (value of `TZ identifier` on webpage).
|
||||
|
||||
3. Information on how to change the port can be found on the [Setup After Installation page](./setup_after_installation.md#port).
|
||||
|
||||
=== "Docker Compose"
|
||||
The contents of the `docker-compose.yml` file are below. The source file can also be found [on GitHub](https://github.com/Casvt/MIND/blob/Development/docker-compose.yml). But before you copy, paste and run it, read the notes below!
|
||||
|
||||
```yml
|
||||
version: "3.3"
|
||||
services:
|
||||
mind:
|
||||
container_name: mind
|
||||
image: mrcas/mind:latest
|
||||
volumes:
|
||||
- "mind-db:/app/db"
|
||||
environment:
|
||||
- TZ=Europe/Amsterdam
|
||||
ports:
|
||||
- 8080:8080
|
||||
|
||||
volumes:
|
||||
mind-db:
|
||||
```
|
||||
|
||||
Then run the following command to start the container. Run this command from within the directory where the `docker-compose.yml` file is located.
|
||||
|
||||
```bash
|
||||
docker-compose up -d
|
||||
```
|
||||
|
||||
A few notes about the `docker-compose.yml` file:
|
||||
|
||||
1. If you're using a folder on the host machine instead of a docker volume to store the database file ([reference](#create-docker-volume-or-folder)), replace `mind-db` with the path to the host folder.
|
||||
E.g. `"/opt/MIND/db:/app/db"`.
|
||||
E.g. `"C:\apps\MIND\db:/app/db"`.
|
||||
|
||||
2. Replace the timezone value (`TZ=`) with the [TZ database name](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones#List) of your timezone (value of `TZ identifier` on webpage).
|
||||
|
||||
3. Information on how to change the port can be found on the [Setup After Installation page](./setup_after_installation.md#port).
|
||||
|
||||
=== "Docker Desktop"
|
||||
1. Click the search bar at the top and search for `mrcas/mind`.
|
||||
2. Click `Run` on the entry saying `mrcas/mind`.
|
||||
3. Open `Images`, and on the right, under `Actions` click the play/run button for `mrcas/mind`.
|
||||
4. Expand the 'Optional settings'.
|
||||
5. For the `Container name`, set the value to `mind`.
|
||||
6. For the `Host port`, set the value to `8080`. Information on how to change the port can be found on the [Setup After Installation page](./setup_after_installation.md#port).
|
||||
7. For the `Host path`, set the value to `mind-db` if you are using a Docker volume for the database. Otherwise, set it to the folder where you want to store the database, [that you created earlier](#create-docker-volume-or-folder). Set the accompanying `Container path` to `/app/db`.
|
||||
8. For the `Variable`, set the value to `TZ`. Set the accompanying `Value` to the [TZ database name](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones#List) of your timezone (value of `TZ identifier` on webpage). E.g. `Europe/Amsterdam`.
|
||||
|
||||
|
||||
## Update instal
|
||||
|
||||
Below you can find instructions on how to update an instal.
|
||||
|
||||
=== "Docker CLI"
|
||||
If needed, run these commands with `sudo`. It is assumed that the name of the container is `mind` (which is set using the `--name` option in the command).
|
||||
|
||||
1. `docker container stop mind`
|
||||
2. `docker container rm mind`
|
||||
3. `docker image rm mrcas/mind:latest`
|
||||
4. Run the command you previously used to start the container.
|
||||
|
||||
=== "Docker Compose"
|
||||
If needed, run these commands with `sudo`. You need to be in the same directory as the `docker-compose.yml` file when running these commands.
|
||||
|
||||
1. `docker-compose down`
|
||||
2. `docker-compose pull`
|
||||
3. `docker-compose up -d`
|
||||
4. `docker image prune -f`
|
||||
|
||||
=== "Docker Desktop"
|
||||
1. Open `Containers` and locate the `mind` container in the list.
|
||||
2. Click the stop button on the right, then the delete button.
|
||||
3. Open `Images` and locate the `mrcas/mind` image in the list.
|
||||
4. Click the delete button on the right.
|
||||
5. Repeat the steps of [launching the container](#launch-container).
|
||||
64
docs/installation/installation.md
Normal file
64
docs/installation/installation.md
Normal file
@@ -0,0 +1,64 @@
|
||||
Installing MIND can be done via Docker or via a manual instal. Docker requires less setup and has better support, but if your OS/system does not support Docker, you can also instal MIND directly on your OS via a manual instal.
|
||||
|
||||
!!! success "Recommended Installation"
|
||||
The recommended way to instal MIND is using Docker.
|
||||
|
||||
For instructions on installing MIND using Docker, see the [Docker installation instructions](./docker.md). For instructions on installing Kapowarr via a manual instal, see the [manual installation instructions](./manual_instal.md).
|
||||
|
||||
The [Setup After Installation page](./setup_after_installation.md) contains the basic steps to take after installing MIND. It's advised to check it out.
|
||||
|
||||
Updating an installation can also be found on the installation pages of the respective installation method.
|
||||
|
||||
## Quick Instructions
|
||||
|
||||
If you already have experience with Docker, then below you can find some quick instructions to get MIND up and running fast. If you need some more guidance, follow the full guide for [Docker](./docker.md) or [a manual instal](./manual_instal.md).
|
||||
|
||||
Replace the timezone value (`TZ=`) with the [TZ database name](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones#List) of your timezone (value of `TZ identifier` on webpage). The database will be stored in a Docker volume.
|
||||
|
||||
=== "Docker CLI"
|
||||
=== "Linux"
|
||||
|
||||
```bash
|
||||
docker run -d \
|
||||
--name mind \
|
||||
-v "mind-db:/app/db" \
|
||||
-e TZ=Europe/Amsterdam \
|
||||
-p 8080:8080 \
|
||||
mrcas/mind:latest
|
||||
```
|
||||
|
||||
=== "MacOS"
|
||||
|
||||
```bash
|
||||
docker run -d \
|
||||
--name mind \
|
||||
-v "mind-db:/app/db" \
|
||||
-e TZ=Europe/Amsterdam \
|
||||
-p 8080:8080 \
|
||||
mrcas/mind:latest
|
||||
```
|
||||
|
||||
=== "Windows"
|
||||
|
||||
```powershell
|
||||
docker run -d --name mind -v "mind-db:/app/db" -e TZ=Europe/Amsterdam -p 8080:8080 mrcas/mind:latest
|
||||
```
|
||||
|
||||
=== "Docker Compose"
|
||||
|
||||
```yml
|
||||
version: "3.3"
|
||||
services:
|
||||
mind:
|
||||
container_name: mind
|
||||
image: mrcas/mind:latest
|
||||
volumes:
|
||||
- "mind-db:/app/db"
|
||||
environment:
|
||||
- TZ=Europe/Amsterdam
|
||||
ports:
|
||||
- 8080:8080
|
||||
|
||||
volumes:
|
||||
mind-db:
|
||||
```
|
||||
49
docs/installation/manual_instal.md
Normal file
49
docs/installation/manual_instal.md
Normal file
@@ -0,0 +1,49 @@
|
||||
On this page, you can find instructions on how to manually instal MIND (directly on the host) and on how to update your manual installation.
|
||||
|
||||
## Installation
|
||||
|
||||
### Time settings
|
||||
|
||||
Make sure to set all time related settings (time, date, timezone, etc.) correct on your computer, as MIND depends on it to work correctly.
|
||||
|
||||
### Installing MIND
|
||||
|
||||
!!! warning
|
||||
These instructions are still under construction.
|
||||
|
||||
=== "Windows"
|
||||
On Windows, there are a couple of extra steps involved.
|
||||
|
||||
1. [Download and instal Python](https://www.python.org/downloads/). This is the framework MIND runs on top of.
|
||||
_Make sure you select to add Python to PATH when prompted. This will make installing requirements much easier._
|
||||
2. Download (or clone) the [latest MIND release](https://github.com/Casvt/MIND/releases/latest).
|
||||
3. Extract the zip file to a folder on your machine.
|
||||
We suggest something straightforward - `C:\apps\MIND` is what we'll use as an example.
|
||||
4. Instal the required python modules (found in `requirements.txt`).
|
||||
This can be done from a command prompt, by changing to the folder you've extracted MIND to and running a python command.
|
||||
```powershell
|
||||
cd C:\apps\MIND
|
||||
python -m pip install -r requirements.txt
|
||||
```
|
||||
5. Run MIND with the command `python C:\apps\MIND\mind.py`.
|
||||
6. Access MIND with the IP of the host machine and port 8080.
|
||||
If it's the machine you're using, try [http://localhost:8080](http://localhost:8080)
|
||||
|
||||
If you want MIND to run in the background, without you having to start it each time your machine restarts, a tool called [nssm](https://nssm.cc/download) will allow you to configure MIND to run as a system service. It is recommended that you set it up as above before doing this, as it will allow you to see any errors you may encounter on screen (instead of having nssm intercept them).
|
||||
|
||||
=== "Ubuntu"
|
||||
```bash
|
||||
sudo apt-get install git python3-pip
|
||||
sudo git clone https://github.com/Casvt/MIND.git /opt/MIND
|
||||
cd /opt/MIND
|
||||
python3 -m pip install -r requirements.txt
|
||||
python3 MIND.py
|
||||
```
|
||||
|
||||
=== "macOS"
|
||||
Use docker.
|
||||
Permissions on macOS (and GateKeeper) make this needlessly complex.
|
||||
|
||||
## Updating instal
|
||||
|
||||
Coming Soon.
|
||||
43
docs/installation/setup_after_installation.md
Normal file
43
docs/installation/setup_after_installation.md
Normal file
@@ -0,0 +1,43 @@
|
||||
After installing MIND, you should have access to the web-ui. MIND needs some configuration in order for it to work properly.
|
||||
|
||||
## Hosting
|
||||
|
||||
There are a few hosting settings which you might want to change, before you continue.
|
||||
|
||||
### Port
|
||||
|
||||
The first thing to do is decide if you want to leave MIND on the default port of `8080`. If you want to _keep_ the port, you can go to the next step. If you want to _change_ the port, see the ['Port' setting](../settings/admin_settings.md#port).
|
||||
|
||||
### Base URL
|
||||
|
||||
If you want to set a base url (e.g. for a reverse proxy), see the ['URL Prefix' setting](../settings/admin_settings.md#url-prefix).
|
||||
|
||||
## Admin panel and settings
|
||||
|
||||
It's handy to check out the admin panel and it's features. Most importantly, you should change the default password of the admin account.
|
||||
|
||||
### Claiming the admin account
|
||||
|
||||
MIND has an admin panel which allows you to manage the users, change hosting and authentication settings and more. To enter the admin panel, login using the username `admin` and password `admin`. Once inside, it's **_strongly_** advised to change the password of the admin account. Instructions on how to do that, can be found on the ['Admin Panel' settings page](../settings/admin_settings.md#user-management).
|
||||
|
||||
### Disabling user registration
|
||||
|
||||
If you are planning on exposing your MIND instance to the internet, it might be smart to disable user registration. This disables the ability for anyone to create a new account. Only the admin will be able to create new user accounts, via the admin panel. See the ['Allow New Accounts' setting](../settings/admin_settings.md#allow-new-accounts).
|
||||
|
||||
## User
|
||||
|
||||
Now we can create and use a normal user account and start making reminders!
|
||||
|
||||
### Creating an account
|
||||
|
||||
When accessing the web-ui, you'll be prompted to log in. Click on `Or create an account`, enter the desired username and password for the account and click `Create` (if user registration is disabled, ask the admin to make an account for you). The account is created and can now be logged in with. The complete authentication process is local and no data is shared with any other service.
|
||||
|
||||
### Set your locale
|
||||
|
||||
In the user settings, you can change your locale, so that the dates and times are displayed in the format used by your country.
|
||||
|
||||
### Add a notification service
|
||||
|
||||
A notification service is a way of sending a notification. For example an e-mail to a group of people or a PushBullet notification to a specific device. What the actual content of the notification is, is decided by the title and text of the reminder. The notification service only specifies in which way the title and text is sent. You set it up once, and then you can select it when creating a reminder.
|
||||
|
||||
Go to the "Notification Services" tab in the web-ui and click the `+` button. Choose a platform, enter the required information and give the service a name. From then on, you can select the notification service when creating/editing a reminder.
|
||||
118
docs/other_docs/reporting.md
Normal file
118
docs/other_docs/reporting.md
Normal file
@@ -0,0 +1,118 @@
|
||||
# Reporting
|
||||
|
||||
This page covers how to get in contact, which platform to use and how to properly share information like logs and errors.
|
||||
|
||||
## Choosing a Platform
|
||||
|
||||
If you have a question, visit the [Discord server](https://discord.gg/nMNdgG7vsE).
|
||||
If you experience behaviour that you are unsure of if it's correct, check the ['General Information' page](../general_info/workings.md).
|
||||
If you are sure that something is going wrong (bug) or is missing (feature), create a [GitHub issue](https://github.com/Casvt/MIND/issues).
|
||||
|
||||
## Reporting a Bug
|
||||
|
||||
If you experience behaviour that is not correct, you should make a 'bug report':
|
||||
|
||||
1. Enable [debug logging](../settings/admin_settings.md#logging-level) in the settings.
|
||||
2. Reproduce the error (this way it will occur with debug logs enabled).
|
||||
3. Collect all the relevant logs. You can download the debug logs from the last debug session by clicking the 'Download Debug Logs' button in the admin panel. Preferably starting from when you started reproducing, but _AT LEAST_ the complete error (A.K.A. traceback).
|
||||
4. On the [GitHub issues page](https://github.com/Casvt/MIND/issues), make a new issue and choose the 'Bug report' template. Fill in each field in the template with the information requested.
|
||||
5. Make sure to properly format code and errors! Otherwise it's not readable. See the tip below.
|
||||
|
||||
### Formatting code and errors
|
||||
|
||||
!!! tip "Formatting code and errors in GitHub"
|
||||
Note: the logs and errors are from Kapowarr, but that does not have an impact on the subject and goal of this text.
|
||||
|
||||
If you want to share logs (that are not the debug logs in the downloaded file), type the following when making a GitHub issue:
|
||||
|
||||
```
|
||||
[2024-01-20 11:20:29][MainThread][INFO] Starting up Kapowarr
|
||||
[2024-01-20 11:20:29][MainThread][INFO] Kapowarr running on http://0.0.0.0:5656/
|
||||
[2024-01-20 11:20:29][Thread-1][INFO] Added task: Update All (1)
|
||||
[2024-01-20 11:20:30][Task Handler][INFO] Finished task Update All
|
||||
```
|
||||
|
||||
It will look like this:
|
||||
|
||||
```
|
||||
[2024-01-20 11:20:29][MainThread][INFO] Starting up Kapowarr
|
||||
[2024-01-20 11:20:29][MainThread][INFO] Kapowarr running on http://0.0.0.0:5656/
|
||||
[2024-01-20 11:20:29][Thread-1][INFO] Added task: Update All (1)
|
||||
[2024-01-20 11:20:30][Task Handler][INFO] Finished task Update All
|
||||
```
|
||||
|
||||
If you want to share code or errors, type the following when making a Github issue:
|
||||
|
||||
```python
|
||||
Traceback (most recent call last):
|
||||
File "/home/nogardvfx/.local/lib/python3.8/site-packages/flask/app.py", line 1455, in wsgi_app
|
||||
 response = self.full_dispatch_request()
|
||||
File "/home/nogardvfx/.local/lib/python3.8/site-packages/flask/app.py", line 869, in full_dispatch_request
|
||||
 rv = self.handle_user_exception(e)
|
||||
File "/home/nogardvfx/.local/lib/python3.8/site-packages/flask/app.py", line 867, in full_dispatch_request
|
||||
 rv = self.dispatch_request()
|
||||
File "/home/nogardvfx/.local/lib/python3.8/site-packages/flask/app.py", line 852, in dispatch_request
|
||||
 return self.ensure_sync(self.view_functions[rule.endpoint])(\*\*view_args)
|
||||
File "/usr/serverApps/Kapowarr/frontend/api.py", line 64, in wrapper
|
||||
 return method(*args, \*\*kwargs)
|
||||
File "/usr/serverApps/Kapowarr/frontend/api.py", line 207, in wrapper
|
||||
 result = method(*args, \*\*kwargs)
|
||||
File "/usr/serverApps/Kapowarr/frontend/api.py", line 398, in api_library_import
|
||||
 result = propose_library_import(limit, only_english)
|
||||
File "/usr/serverApps/Kapowarr/backend/library_import.py", line 174, in propose_library_import
|
||||
 search_results = run(__search_matches(
|
||||
File "/usr/lib/python3.8/asyncio/runners.py", line 44, in run
|
||||
 return loop.run_until_complete(main)
|
||||
File "/usr/lib/python3.8/asyncio/base_events.py", line 616, in run_until_complete
|
||||
 return future.result()
|
||||
File "/usr/serverApps/Kapowarr/backend/library_import.py", line 37, in __search_matches
|
||||
 responses = await gather(*tasks)
|
||||
File "/usr/serverApps/Kapowarr/backend/comicvine.py", line 597, in search_volumes_async
|
||||
 return self.__process_search_results(query, results)
|
||||
File "/usr/serverApps/Kapowarr/backend/comicvine.py", line 483, in __process_search_results
|
||||
 results = [self.__format_volume_output(r) for r in results]
|
||||
File "/usr/serverApps/Kapowarr/backend/comicvine.py", line 483, in
|
||||
 results = [self.__format_volume_output(r) for r in results]
|
||||
File "/usr/serverApps/Kapowarr/backend/comicvine.py", line 303, in __format_volume_output
|
||||
 result['volume_number'] = int(volume_result.group(1))
|
||||
ValueError: invalid literal for int() with base 10: 'i'
|
||||
```
|
||||
|
||||
It will look like this:
|
||||
|
||||
```python
|
||||
Traceback (most recent call last):
|
||||
File "/home/nogardvfx/.local/lib/python3.8/site-packages/flask/app.py", line 1455, in wsgi_app
|
||||
response = self.full_dispatch_request()
|
||||
File "/home/nogardvfx/.local/lib/python3.8/site-packages/flask/app.py", line 869, in full_dispatch_request
|
||||
rv = self.handle_user_exception(e)
|
||||
File "/home/nogardvfx/.local/lib/python3.8/site-packages/flask/app.py", line 867, in full_dispatch_request
|
||||
rv = self.dispatch_request()
|
||||
File "/home/nogardvfx/.local/lib/python3.8/site-packages/flask/app.py", line 852, in dispatch_request
|
||||
return self.ensure_sync(self.view_functions[rule.endpoint])(**view_args)
|
||||
File "/usr/serverApps/Kapowarr/frontend/api.py", line 64, in wrapper
|
||||
return method(*args, **kwargs)
|
||||
File "/usr/serverApps/Kapowarr/frontend/api.py", line 207, in wrapper
|
||||
result = method(*args, **kwargs)
|
||||
File "/usr/serverApps/Kapowarr/frontend/api.py", line 398, in api_library_import
|
||||
result = propose_library_import(limit, only_english)
|
||||
File "/usr/serverApps/Kapowarr/backend/library_import.py", line 174, in propose_library_import
|
||||
search_results = run(__search_matches(
|
||||
File "/usr/lib/python3.8/asyncio/runners.py", line 44, in run
|
||||
return loop.run_until_complete(main)
|
||||
File "/usr/lib/python3.8/asyncio/base_events.py", line 616, in run_until_complete
|
||||
return future.result()
|
||||
File "/usr/serverApps/Kapowarr/backend/library_import.py", line 37, in __search_matches
|
||||
responses = await gather(*tasks)
|
||||
File "/usr/serverApps/Kapowarr/backend/comicvine.py", line 597, in search_volumes_async
|
||||
return self.__process_search_results(query, results)
|
||||
File "/usr/serverApps/Kapowarr/backend/comicvine.py", line 483, in __process_search_results
|
||||
results = [self.__format_volume_output(r) for r in results]
|
||||
File "/usr/serverApps/Kapowarr/backend/comicvine.py", line 483, in
|
||||
results = [self.__format_volume_output(r) for r in results]
|
||||
File "/usr/serverApps/Kapowarr/backend/comicvine.py", line 303, in __format_volume_output
|
||||
result['volume_number'] = int(volume_result.group(1))
|
||||
ValueError: invalid literal for int() with base 10: 'i'
|
||||
```
|
||||
|
||||
See the difference? That's why it's important to properly format logs and code when sharing them.
|
||||
55
docs/settings/admin_settings.md
Normal file
55
docs/settings/admin_settings.md
Normal file
@@ -0,0 +1,55 @@
|
||||
Here you can find documentation on the admin settings, which are the settings available in the admin panel.
|
||||
|
||||
## Authentication
|
||||
|
||||
### Allow New Accounts
|
||||
|
||||
Whether or not people that access the web-ui have the option to create an account. When disabled, it is not possible to create new accounts, except for the admin via the admin panel.
|
||||
|
||||
### Login Time
|
||||
|
||||
The authentication timeout. For how long users stay logged in before they have to authenticate again.
|
||||
|
||||
### Login Time Trigger
|
||||
|
||||
Whether or not to reset the login timer (A.K.A. the authentication timeout) when using MIND. If the value is set to `After Login`, the timer will start counting after the user has logged in and will force the user the authenticate again once it has run out. If the value is set to `After Last Use`, the timer will start counting after the last time the user used MIND. So if the timeout is long enough that the user will consistently use MIND more regularly than the timeout duration, the user wouldn't need to authenticate ever again (until they don't use MIND for long enough that the timer runs out).
|
||||
|
||||
## Logging
|
||||
|
||||
### Logging Level
|
||||
|
||||
Keep this at `Info` in normal situations. If you encounter a problem and need to share logs, set this to `Debug` and recreate the problem. Then set it back to `Info` again. More information on this on the ['Reporting' page](../other_docs/reporting.md) and [general info page on the admin panel](../general_info/admin_panel.md#logging).
|
||||
|
||||
## Hosting
|
||||
|
||||
Any changes to these settings will restart MIND immediately. The changes are applied and MIND will start running with the new hosting settings. **_If you do not log into the admin panel within one minute after restarting, the changes will be reverted._** This means that MIND will basically 'try out' the new hosting settings for one minute. If you haven't logged into the admin panel within that one minute after restart, the changes will be canceled, the old hosting settings will be applied and MIND will be restarted again. By logging into the admin panel, you keep the hosting settings. This feature is useful if you change the hosting settings in such way that the UI becomes unreachable; simply wait one minute and the changes will be reverted.
|
||||
|
||||
### Host
|
||||
|
||||
This tells MIND what IP to bind to. If you specify an IP that is _not_ on the machine running MIND, you _will_ encounter errors.
|
||||
Using `0.0.0.0` will have MIND bind to all interfaces it finds on the host machine.
|
||||
|
||||
_Note: this setting is not applicable if you have MIND deployed using Docker._
|
||||
|
||||
### Port
|
||||
|
||||
This tells MIND what port to listen on. The default is `8080`, which would put the MIND UI on `http://{HOST}:8080/`.
|
||||
|
||||
If you have MIND deployed using Docker, do not change this setting but instead follow the instructions below:
|
||||
|
||||
=== "Docker CLI"
|
||||
Alter the command to run the container by replacing `-p 8080:8080` with `-p {PORT}:8080`, where `{PORT}` is the desired port (e.g. `-p 8009:8080`). Run the container with the new version of the command (you will need to remove the old container if you had it running before).
|
||||
|
||||
=== "Docker Compose"
|
||||
Alter the file to run the container and replace `- 8080:8080` with `- {PORT}:8080`, where `{PORT}` is the desired port (e.g. `- 8009:8080`). Then re-run the container with the new version of the file.
|
||||
|
||||
=== "Docker Desktop"
|
||||
1. Open `Containers` and locate the `mind` container in the list.
|
||||
2. Click the stop button on the right, then the delete button.
|
||||
3. Follow the [instructions for launching the container](../installation/docker.md#launch-container), starting from step 3. At step 6, set the value to the desired port. For example, if you set it to `8009`, the web-UI will then be accessible via `http://{host}:8009/`. Continue following the rest of the steps.
|
||||
|
||||
### URL Prefix
|
||||
|
||||
This is used for reverse proxy support - the default is empty. If you want to put MIND behind a proxy (so you can access the web-UI via a nice URL), set a URL prefix (it _must_ start with a `/` character).
|
||||
|
||||
To get MIND running on `http://example.com/mind`, you would set your reverse proxy to forward the `/mind` path to the IP and port of your mind instance, and set URL prefix to `/mind`.
|
||||
3
docs/settings/settings.md
Normal file
3
docs/settings/settings.md
Normal file
@@ -0,0 +1,3 @@
|
||||
# Introduction
|
||||
|
||||
You can find documentation for all settings here. They are divided into two parts: [user settings](./user_settings.md) and [admin settings](./admin_settings.md). User settings are the settings available to a normal user, in the settings tab. Admin settings are the settings available in the admin panel.
|
||||
9
docs/settings/user_settings.md
Normal file
9
docs/settings/user_settings.md
Normal file
@@ -0,0 +1,9 @@
|
||||
Here you can find documentation on the user settings, which are the settings available to a normal user, in the settings tab.
|
||||
|
||||
## Locale
|
||||
|
||||
This setting is for formatting times and dates according to the format used in the set county. It's advised to set the value to the country that you live in.
|
||||
|
||||
## Default Notification Service
|
||||
|
||||
This setting decides which notification service is selected by default when creating a new reminder.
|
||||
@@ -1,34 +0,0 @@
|
||||
# Setup After Installation
|
||||
|
||||
After installing MIND, you should have access to the web-ui. MIND needs some configuration in order for it to work properly.
|
||||
|
||||
## Port
|
||||
|
||||
The first thing to do is decide if you want to leave MIND running on the default port of `8080`. If you _do_, you can go to the next step. If you want to _change_ the port, continue reading.
|
||||
|
||||
=== "Docker CLI"
|
||||
Alter the command to run the container and replace `-p 8080:8080` with `-p {PORT}:8080`, where `{PORT}` is the desired port (e.g. `-p 8009:8080`). Then run the container with the new version of the command.
|
||||
|
||||
=== "Docker Compose"
|
||||
Alter the file to run the container and replace `- 8080:8080` with `- {PORT}:8080`, where `{PORT}` is the desired port (e.g. `- 8009:8080`). Then run the container with the new version of the file.
|
||||
|
||||
=== "Manual Install"
|
||||
Inside the `MIND.py` file at the top, you can set the port via the `PORT` variable. Change it from `PORT = '8080'` to `PORT = '{PORT}'`, where `{PORT}` is the desired port (e.g. `PORT = '8009'`). Then restart the application.
|
||||
|
||||
## Base URL
|
||||
|
||||
If you want to set a base url (e.g. for a reverse proxy), go inside the `MIND.py` file and at the top, you can set the base URL via the `URL_PREFIX` variable. Change it from `URL_PREFIX = ''` to `URL_PREFIX = '/{PREFIX}'`, where `{PREFIX}` is the desired URL prefix (e.g. `URL_PREFIX = '/mind'`). Then restart the application.
|
||||
|
||||
## Creating an account
|
||||
|
||||
When accessing the web-ui, you'll be prompted to log in. Click on `Or create an account`, enter the desired username and password for the account and click `Create`. The account is created and can now be logged in with. The complete authentication process is local and no data is shared with any other service.
|
||||
|
||||
## Set your locale
|
||||
|
||||
In the settings, you can change your locale, so that the dates and times are displayed in the format used by your country.
|
||||
|
||||
## Add a notification service
|
||||
|
||||
A notification service is a way of sending a notification. For example an e-mail to a group of people or a PushBullet notification to a specific device. What the actual content of the notification is, is decided by the title and text of the reminder. The notification service only specifies in which way the title and text is sent. You set it up once, and then you can select it when creating a reminder.
|
||||
|
||||
Go to the "Notification Services" tab in the web-ui and click the `+` button. A notification service consists of a title (name) and an Apprise URL. See the [Apprise URL documentation](https://github.com/caronc/apprise#supported-notifications) to learn how to make a valid Apprise URL.
|
||||
@@ -810,7 +810,7 @@ def api_admin_user(inputs: Dict[str, Any], u_id: int):
|
||||
|
||||
@admin_api.route(
|
||||
'/database',
|
||||
'Download the database',
|
||||
'Download and upload the database',
|
||||
Methods(
|
||||
get=Method(
|
||||
description="Download the database file"
|
||||
|
||||
@@ -2,6 +2,10 @@ main {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
main a {
|
||||
color: var(--color-light);
|
||||
}
|
||||
|
||||
.action-buttons {
|
||||
--spacing: .5rem;
|
||||
|
||||
|
||||
@@ -129,6 +129,7 @@
|
||||
<button type="submit" id="save-hosting-button">Save and Restart</button>
|
||||
</div>
|
||||
<p>IMPORTANT: After saving the hosting settings, it is required to log into the admin panel within 1 minute (60 seconds) in order to keep the new hosting settings. Otherwise, MIND will revert the changes and go back to the old hosting settings.</p>
|
||||
<p>See <a href="https://casvt.github.io/MIND/settings/admin_settings#hosting">the documentation</a> for more information.</p>
|
||||
</form>
|
||||
<h2>User Management</h2>
|
||||
<div class="add-user-container">
|
||||
@@ -198,9 +199,8 @@
|
||||
</table>
|
||||
</div>
|
||||
<button type="submit" id="upload-db-button">Import Database</button>
|
||||
<p>Restore a backup.</p>
|
||||
<p>Note: The uploaded file can be denied if it is not a valid database file, is too old or is for a newer version than this MIND instance.</p>
|
||||
<p>IMPORTANT: After uploading the backup, it is required to log into the admin panel within 1 minute (60 seconds) in order to keep the new database file. Otherwise, MIND will revert the upload and go back to the old database.</p>
|
||||
<p>See <a href="https://casvt.github.io/MIND/general_info/admin_panel#database">the documentation</a> for more information.</p>
|
||||
</form>
|
||||
<h2>Power</h2>
|
||||
<div class="database-container">
|
||||
|
||||
@@ -16,6 +16,8 @@ from frontend.api import (NotificationServiceNotFound, ReminderNotFound,
|
||||
from frontend.input_validation import DataSource, api_docs
|
||||
|
||||
api_prefix = SERVER.api_prefix
|
||||
admin_prefix = SERVER.admin_prefix
|
||||
api_file = folder_path('docs', 'other_docs', 'api.md')
|
||||
|
||||
url_var_map = {
|
||||
'int:n_id': NotificationServiceNotFound,
|
||||
@@ -54,9 +56,11 @@ curl -sSL 'http://192.168.2.15:8080{api_prefix}/reminders?api_key=ABCDEFG'
|
||||
|
||||
## Supplying data
|
||||
|
||||
Often, data needs to be supplied with a request.
|
||||
If the parameters need to be supplied via `url`, add them to the url as url parameters.
|
||||
If the parameters need to be supplied via `body`, add them to the body as a json object and supply the `Content-Type: application/json` header.
|
||||
Often, data needs to be supplied with a request:
|
||||
|
||||
- If the parameters need to be supplied via `url`, add them to the url as url parameters.
|
||||
- If the parameters need to be supplied via `body`, add them to the body as a json object and supply the `Content-Type: application/json` header.
|
||||
- If the parameters need to be supplied via `file`, send them as form data values and supply the `Content-Type: multipart/form-data` header.
|
||||
|
||||
For example:
|
||||
```bash
|
||||
@@ -68,6 +72,13 @@ curl -sSLX POST \\
|
||||
-H 'Content-Type: application/json' \\
|
||||
-d '{{"title": "Test service", "url": "test://fake/url"}}' \\
|
||||
'http://192.168.2.15:8080{api_prefix}/notificationservices?api_key=ABCDEFG'
|
||||
|
||||
# File parameter
|
||||
curl -sSLX POST \\
|
||||
-H 'Content-Type: multipart/form-data' \\
|
||||
-F file=@/backups/MIND_backup.db \\
|
||||
'http://192.168.2.15:8080{admin_prefix}/database?api_key=ABCDEFG'
|
||||
|
||||
```
|
||||
|
||||
## Endpoints
|
||||
@@ -133,18 +144,18 @@ Replace `<{url_var}>` with the ID of the entry. For example: `{rule.replace(f'<{
|
||||
|
||||
result += '\n'
|
||||
|
||||
with open(folder_path('docs', 'api.md'), 'r') as f:
|
||||
with open(api_file, 'r') as f:
|
||||
current_content = f.read()
|
||||
|
||||
if current_content == result:
|
||||
print('Nothing changed')
|
||||
else:
|
||||
with open(folder_path('docs', 'api.md'), 'w+') as f:
|
||||
with open(api_file, 'w+') as f:
|
||||
f.write(result)
|
||||
|
||||
run(["git", "config", "--global", "user.email", '"casvantijn@gmail.com"'])
|
||||
run(["git", "config", "--global", "user.name", '"CasVT"'])
|
||||
run(["git", "checkout", "Development"])
|
||||
run(["git", "add", folder_path('docs', 'api.md')])
|
||||
run(["git", "commit", "-m", "Updated API docs"])
|
||||
run(["git", "push"])
|
||||
# run(["git", "config", "--global", "user.email", '"casvantijn@gmail.com"'])
|
||||
# run(["git", "config", "--global", "user.name", '"CasVT"'])
|
||||
# run(["git", "checkout", "Development"])
|
||||
# run(["git", "add", api_file])
|
||||
# run(["git", "commit", "-m", "Updated API docs"])
|
||||
# run(["git", "push"])
|
||||
|
||||
@@ -46,6 +46,7 @@ theme:
|
||||
# Markdown extensions
|
||||
markdown_extensions:
|
||||
- abbr
|
||||
- admonition
|
||||
- attr_list
|
||||
- meta
|
||||
- pymdownx.details
|
||||
@@ -63,7 +64,7 @@ markdown_extensions:
|
||||
- sane_lists
|
||||
- toc:
|
||||
permalink: true
|
||||
toc_depth: 5
|
||||
toc_depth: 3
|
||||
- tables
|
||||
|
||||
# mkdocs function extensions
|
||||
@@ -77,9 +78,19 @@ plugins:
|
||||
# Navigation Layout
|
||||
nav:
|
||||
- Home: index.md
|
||||
- Getting Started:
|
||||
- Installation: installation.md
|
||||
- Setup After Installation: setup_after_installation.md
|
||||
- Installation And Updating:
|
||||
- Introduction: installation/installation.md
|
||||
- Docker: installation/docker.md
|
||||
- Manual Instal: installation/manual_instal.md
|
||||
- Setup After Installation: installation/setup_after_installation.md
|
||||
- General Information:
|
||||
- Introduction: general_info/workings.md
|
||||
- Reminders: general_info/reminders.md
|
||||
- Admin Panel: general_info/admin_panel.md
|
||||
- Settings:
|
||||
- Introduction: settings/settings.md
|
||||
- User Settings: settings/user_settings.md
|
||||
- Admin Settings: settings/admin_settings.md
|
||||
- Other Docs:
|
||||
- API: api.md
|
||||
- Backup Your Data: backup_your_data.md
|
||||
- Reporting: other_docs/reporting.md
|
||||
- API: other_docs/api.md
|
||||
|
||||
Reference in New Issue
Block a user