Creekside
Home
Blog
Plantation One HOA
Log in
Zappa and Django installed
Grey Brinson
January 30, 2022
<p style="margin-bottom: 1rem;">So, following the three previously mentioned web sites and "Google engineering" the occasional issues that popped up, Zappa and Django were installed on my AWS Cloud9 instance. My first app is this blog. I was able to use my existing RDS MySQL database, along with most of my existing templates</p><p style="margin-bottom: 1rem;">Django has a lot of builtin features. One example relates to models and database tables. One can define the table items in the models.py file for the app and run the migration and it will build the table for you. This is not an uncommon feature for MVC or MVT platforms. I performed this operation and it worked perfectly, but I was curious about what options I had if had wanted to use my existing table from the Chalice project. </p><p style="margin-bottom: 1rem;">It turns out that I could have run manage.py with the "inspectdb" option and it would have spit out the model definitions for all the tables in the database. One can then just add these definitions to the models.py and keep on going. </p><p style="margin-bottom: 1rem;">This wasn't a big deal with my little one table blog, but this could be a massive head start for someone porting over a large multi table app with lots of relationships. Using the generic views, one could have CRUD functionality set up very quickly.</p>
Back to List