We need to tell the admin that the ATMlocations objects have an admin interface:
- To do this, open the atmapp/admin.py file and edit it to look like the following code block:
[root@ip-172-31-95-213 atmproject]# vi atmapp/admin.py
------------------------------------------
from django.contrib import admin
# Register your models here.
from .models import ATMlocations
admin.site.register(ATMlocations)
------------------------------------------
- Then, we can launch the Django server with the help of the following command:
(venv) [root@ip-172-31-95-213 atmproject]# python3.7 manage.py runserver 0:8000
- After that, we will log in as the admin at http://ec2-3-209-184-46.compute-1.amazonaws.com:8000/admin. Using the admin and djangoapp login credentials, we will be able to view our captured ATM locations data from the PostgreSQL RDS, as shown in the following screenshot:
Figure 4.18 – Registering the database...