Back to Home

sw_deploy

Overview Develop Deploy Data

This application is deployed on Google Cloud Platform using App Engine Flexible Environment, CloudSQL (PostgreSQL), Cloud Storage and Firebase.

sw_deploy_workflow

Getting Started

Database - Cloud SQL

database

Connect Django to Google Cloud SQL with a PostgreSQL instance to deploy Django to Google App Engine. The PostgreSQL instance has read replicas and high availability to replicate that of a cluster environment for distributed data sharing.

File Storage - Cloud Storage

sw_deploy_storage

All static and media files are on Google Cloud Storage (for this application this was the best choice over a DFS)

Media:

Use Django Storage to allow media files to be served from Google Cloud Storage. Media images are stored in seperate folder for each app (post_pics, country_pics and profile_pics).

Static:

Backend - Google App Engine

sw_deploy_backend

Django was deployed on Google Flexible Environment with some helpful guidelines.

When deployed it is converted to a docker image and run on a default of 2 VM instances. It looks at the applications app.yaml file for the relevant information (eg. Runtime environment, environment variables, etc).

Frontend - Google Firebase

sw_deploy_frontend

Originally to be deployed on app engine, however this was not the best option. Instead, deployed on Google Firebase which is designed for easy deployment of frontend apps. Due to the API nature of this program and Django they could be deployed separately. This structure provided greater efficiency and results then when running together locally.