Visão Geral
O curso Deploying Django REST Framework APIs on Google Cloud foi desenvolvido para profissionais que desejam aprender, de forma prática e aplicada, como implantar APIs criadas com Django REST Framework (DRF) utilizando os serviços e recursos da Google Cloud Platform (GCP).
Durante o curso, os alunos aprenderão desde a configuração e containerização da aplicação até a implantação em Google App Engine e Cloud Run, abordando também integração com Cloud SQL, Cloud Storage, IAM, Secret Manager e Cloud Monitoring.
Conteúdo Programatico
Module 1: Introduction to Django REST Framework and Google Cloud
- Overview of Django and Django REST Framework
- Understanding RESTful APIs and scalability
- Introduction to Google Cloud Platform (GCP)
- Deployment options: App Engine, Cloud Run, GKE, and Compute Engine
Module 2: Building and Testing the API
- Setting up a Django project and installing DRF
- Creating models, serializers, and API views
- Authentication and permissions
- Testing endpoints locally with Postman and Django test client
Module 3: Preparing for Deployment
- Managing environment variables and settings
- Static and media file management
- Production configuration (Gunicorn, WhiteNoise, etc.)
- Creating requirements.txt and environment configuration
Module 4: Containerizing the Application with Docker
- Docker basics and container concepts
- Writing a Dockerfile for Django
- Building and testing the image locally
- Using Docker Compose for multi-service setup
- Debugging and optimizing container builds
Module 5: Deploying to Google App Engine
- Overview of App Engine environments (standard vs flexible)
- Writing app.yaml configuration
- Deploying Django to App Engine
- Connecting to Cloud SQL from App Engine
- Managing scaling, versions, and traffic splitting
Module 6: Deploying to Google Cloud Run
- Introduction to Cloud Run (serverless containers)
- Building and pushing the Docker image to Artifact Registry
- Deploying the container with Cloud Run CLI
- Environment variables and secret management
- Setting up HTTPS and domain mapping
Module 7: Data and Storage Integration
- Using Cloud SQL for relational data
- Configuring connections with SQLAlchemy or psycopg2
- Managing static and media files on Cloud Storage
- Cloud IAM roles and permissions
Module 8: CI/CD Automation
- Overview of CI/CD pipelines in GCP
- Automating deployments with Cloud Build
- Integrating with GitHub Actions for continuous delivery
- Rollback strategies and blue/green deployments
Module 9: Security and Observability
- Using Google Secret Manager for secure credentials
- IAM roles, service accounts, and access control
- Logging and monitoring with Cloud Logging and Monitoring
- Distributed tracing with Cloud Trace and Error Reporting
Module 10: Final Project — Complete API Deployment
- Building a real Django REST API
- Containerizing and deploying to Cloud Run
- Integrating Cloud SQL and Cloud Storage
- Setting up monitoring, logs, and alerts
- Best practices for production readiness