mirror of https://github.com/msgbyte/tailchat
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
747 B
747 B
sidebar_position | title |
---|---|
1 | Database management |
Tailchat
uses mongodb as the main database to store user information
In docker
, common operation and maintenance commands are as follows:
# backup
docker exec -i <IMAGE_NAME> mongodump -d tailchat --archive > ./backup.archive
# restore
docker exec -i <IMAGE_NAME> mongorestore -d tailchat --archive < ./backup.archive
Among them <IMAGE_NAME>
represents the name of the mongodb image, and -d tailchat
represents the name of the database used, the default database name is tailchat
, you can modify it through the environment variable MONGO_URL
:::info For user data security, it is recommended to create a scheduled task to regularly back up the database file :::