MyLibrary is an application for cataloging your books library. The application is designed to help unite lovers of literature. Find a rare book among users MyLibrary.
It's server part - Cement
- server data backup
- cleaning up obsolete files and data
- sending firebase push messages
mylibrary backup -t=db
Back up the database. You can specify a folder or ftp in the configuration file.
mylibrary backup -t=tar
Back up the files or dirs in tar.gz. For compression use pigz (& tar) with multi-stream archive build capability.
mylibrary cleaner -t=tokens
Clearing obsolete tokens from the database. Application specific.
# find method in the project for change
def clear_old(cls, app):
mylibrary cleaner -t=images
Clearing non-database images in the folder specified in the configuration file.
mylibrary notification
Messaging google push firebase. Application specific. You need to build a request for a specific database.
# find method in the project for change
def find_open(cls, app):
# 15 days
mylibrary reminder -d=15
# 25 days
mylibrary reminder -d=25
Create reminder notification for 15 day and 25 day if user not open application. Application specific.
# find Controller in the project for change
class Reminder(Controller):
0 1 * * * /snap/bin/mylibrary backup -t=db
0 1 * * * /snap/bin/mylibrary backup -t=tar
0 1 * * * /snap/bin/mylibrary cleaner -t=tokens
0 1 * * * /snap/bin/mylibrary cleaner -t=images
0 1 * * * /snap/bin/mylibrary reminder -d=15
0 1 * * * /snap/bin/mylibrary reminder -d=25
*/5 * * * * /snap/bin/mylibrary notification