Reputation: 1307
I am developing a personal website using Django (to learn).
I want to also save it on GitHub.
Where to store the database [file] itself? Not on GitHub?
If I want to make a save a copy of the database in case it vanishes, where does one typically upload their database?
If my website is a "production" website with enough content, what would be the best practice?
Upvotes: 0
Views: 305
Reputation: 121
The short answer: with the source files.
When using databases with Client-Server architecture such as MySQL, MongoDB, PostgreSQL, it's better to keep backups safely on servers.
However, SQLite is a server-less database and is self-contained, which is perfect for personal website.
Essentially it's an embedded database which means the DB engine runs as a part of the app.
In this particular situation it's completely fine to keep the database file within app's source files.
Edit: if the plan is to store some important data (e.g. auth), it's better to use some service with cloud DB.
Upvotes: 1