A nifty web app to keep track of my home's monthly expenses and some personal utility.
Developed and hosted on Raspberry Pi 4 with neovim as code editor.
- Multi account support for family members and shared payment information records for each bill
- Monthly fixed bills records plus bill adjustments
- Personal expenses records
- Personal TODO list
-
Clone this repository.
git clone https://github.com/s-shifat/home-finance.git
1.2. Create a virtual environment. I used virtualenv:
# Navigate to project root. cd home-finance # Create virtual environment virtualenv venv # If you use Linux/Mac source venv/bin/activate # If you're in fish shell source venv/bin/activate.fish # If you use Windows powershell .\venv\Scripts\activate.ps1
-
Install requirements:
pip install -r requirements.txt
-
To launch on local host:
python manage.py runserver
... That's it!
To launch on a Raspberry there are many ways. I followed this one:
-
ssh into your pi.
-
Make
start.sh
executablesudo chmod +x ./start.sh
-
Edit your
/etc/rc.local
file.sudo vim /etc/rc.local
The last satement in this file is
exit 0
. You will add the following line just aboveexit 0
:bash absolute_path_to_start.sh &
replace
absolute_path_to_start
with absolute path of start.sh in your rasberry pi. A reboot might be required after that.
To configure other databases you can use creds
directory. Here's an example to use PostgreSQL:
-
Install and setup PostgreSQL in your system. I followed this guide. Make note of name, password, server and port.
-
Create a copy of sqlite_db.py inside
creds
directory and rename it to something likepostgresql_db.py
. -
Now edit the file as following with your proper credentials:
MY_DB_CONFIG = {
'ENGINE': 'django.db.backends.postgresql_psycopg2',
'NAME': 'your_db_name_here',
'USER': 'your_user_name_here',
'PASSWORD': 'your_password_here',
'HOST': 'host_url_here',
'PORT': 'port_here',
}
-
Now use it in the
settings.py
accordingly:Import the
postgresql_db.py
file you have just created.
from creds.postgresql_db import MY_DB_CONFIG
Then, look for the dictionary named DATABASES
and make it look like:
DATABASES = {
"default": MY_DB_CONFIG,
}
... And that's all!
Here is another comprehensive example.
See who contributed in the bills.
Pay or adjust as you wish.
Track items by category. Create category on the fly!
Create separate lists, add tasks and mark/unmark tasks!