Local Mail Server implementation using Django
Steps to run the code: (in Windows)
- pip install virtualenv
- cd
- virtualenv
- Scripts\activate.bat
- clone repository as 'mailclient' in
- cd mailclient
- pip install -r requirements.txt
- create database 'mailclient' in mysql
- python manage.py migrate
- python manage.py createsuperuser --> user: admin --> email: admin@example.com --> password: 123456
- python manage.py runserver
- go to http://127.0.0.1:8000/admin/
- create users there. (create atleast 2 users) For example: user: a@example.com password: 123456
- logout from admin site
- open 2 browser windows (one in normal and other in incognito)
- log on to http://127.0.0.1:8000/
- log in with 2 different accounts in 2 windows
- Compose an email in one and click send
- Refresh the other manually to see recieved messages.
- Similarly do vice-versa. Also emails are visible on command prompt and are stored in db.
- deactivate (in cmd) and exit
Important: configure your MySql db host, port and pass in mailClient/settings.py
For Linux and Mac machines only the virtualenv code will change