March 30, 2021, 10:13 p.m. Django Blog


   An easy-to-use and modifiable platform were desired to showcase professional information, projects, resources, and function as an API for small applications.


   One of the first considerations was which framework to use. Django was chosen due to its default functionality and the that it uses python. It provides a lot of configuration options as well as a friendly admin interface to add content. Flask was considered however it would require more effort in building the functionality the Django already provides from the beginning. The next consideration was the platform to host the application on. Amazon Web Services (AWS) provides various services for hosting an application, as well as configuring the environment, database, and pipeline. Elastic Beanstalk (EB) was used to host and set up the platform; here information such as the username and password used for accessing the database was stored. The environment and the associated Elastic Compute Cloud (EC2) instance were configured to have access to the GDAL library for any Geographic Information Science (GIS) functionalities that may be implemented in the future. A PostgreSQL database hosted on AWS's Relational Database Service (RDS) was created to store in associated data. S3 was used to store static, media, and data files. Finally, the Code Pipeline Service was used to push any changes made to the GitHub containing the code for this project.


    Some of the largest issues revolved around getting the application to handle geographic datasets. Mainly getting the EC2 instance set up with GDAL and its requirements. The solution that was used consisted of making a script to download the appropriate files and run the necessary commands. Next, a modified model was created and a custom signal function would run after uploading a geographic dataset (GeoJSON). Before including the database in the process, the dataset was parsed and stored in the database. This would allow queries to be made; for this application, the returned query would be displayed on a leaflet map.
   Another large issue was the overall set up with the various AWS services, especially the EC2 and EB instance. Many settings in both Django and EB had to be properly configured if the application was to run correctly. One example includes collecting the static files and placing them in S3 or setting up the application to pull static files from S3.