| Aspect | Description |
|---|---|
| Pre-installed Tools | AWS SAM CLI and AWS CLI pre-installed in Cloud9 |
| Benefits | - Faster Development Environment Setup - Streamlined Workflow - Simplified Management |
| Development Focus | - Development of Full-Stack Application - Configuration with SAM Templates - Deployment and Testing |
| Environment Advantages | - Jump right into project development - Seamlessly switch between SAM templates and AWS CLI - No worry about versioning conflicts or updates |
| Project Aspects | - Build functionalities and user interface- Define serverless infrastructure using SAM templates- Utilize AWS CLI and SAM for build, deploy, and test |
| Prerequisite | Link | Additional Information |
|---|---|---|
| AWS Account | Create AWS Account | Free tier available for new users |
| GitHub Account | GitHub Signup | Consider enabling two-factor authentication |
| AWS CLI | AWS CLI Installation Guide | Ensure it's configured with your AWS credentials |
| Docker | Docker Desktop | Required for local development and testing |
| NPM | NPM Installation | Comes bundled with Node.js |
| Node.js | Node.js Download | LTS version recommended |
| AWS SAM CLI | SAM CLI Installation | Configure on Cloud9 or local machine |
| Domain Name | [AWS Route 53](https://aws.amazon.co |
| Section | Description | Additional Information |
|---|---|---|
| 1. Account Setup and Domain Registration | - AWS Account Setup - Domain name registration |
- Use AWS Route 53 for domain registration if possible - Ensure AWS account has necessary permissions |
| 2. Develop your Application | - Develop full-stack application - Front-end: static website or SPA - Back-end: serverless functions (Node.js, Python, etc.) |
- Use React for front-end - TypeScript for back-end - Implement necessary API endpoints |
| 3. Deploy with AWS SAM CLI | - Use AWS SAM CLI commands:sam buildsam packagesam deploy |
- Ensure AWS SAM CLI is installed and configured - Run commands from Cloud9 terminal or local environment |
| 4. Define your SAM Template | - Create template.yaml file- Define resources: Lambda, API Gateway, S3, CloudFront |
- Use YAML syntax - Reference AWS SAM documentation for resource properties |
| 5. Configure Secure HTTPS |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| set -euo pipefail | |
| # Configuration | |
| DEFAULT_USER_SUFFIX="-cli" | |
| DEFAULT_GROUP="Admins" | |
| DEFAULT_POLICY="AdministratorAccess" | |
| AWS_CREDENTIALS_FILE="$HOME/.aws/credentials" | |
| # Functions |
| Prerequisite | Resource Link |
|---|---|
| Basic knowledge of Django | https://docs.djangoproject.com/en/4.2/intro/tutorial01/ |
| AWS Account | https://aws.amazon.com/free/ |
| GitHub Account | https://github.com/join |
| AWS CLI | https://aws.amazon.com/cli/ |
| EKS CLI | https://docs.aws.amazon.com/eks/latest/userguide/eksctl.html |
| Docker | https://www.docker.com/get-started/ |
| TypeScript | https://www.typescriptlang.org/download |
| Postman | https://www.postman.com/downloads/ |
| Step | Details |
|---|---|
| Initial Environment Setup | Register your AWS Account; Register your domain name; Create AWS Key Pairs; Create AWS Access Keys; Setup Django Application; Dockerize the Django Application |
| GitHub Repository Setup | Create a GitHub repository for your Django application; Add your Django code to this repository. |
| Continuous Integration with GitHub Actions | Configure GitHub Actions workflows to run tests, linting, and other checks; Utilize Docker containers for consistency across different environments. |
| Infrastructure Provisioning with Terraform | Define infrastructure requirements using Terraform; Provision necessary AWS resources (like EC2 instances, VPC, subnets, etc.) for the Jenkins server, Kubernetes cluster, and other required services. |
| Continuous Deployment with Jenkins | Set up Jenkins on a server; Configure Jenkins pipelines to trigger on successful CI builds; Build Docker images for your Django application; Push Docker images to a Docker registry; |
This playbook provides guidance on using Gource to visualize the history of a Git repository. It covers installing Gource, generating visualizations, customizing visual output, and sharing the visualization.
- Ensure Gource is installed on your machine by following the official installation guide: https://github.com/acaudwell/Gource#install
- Have a Git repository cloned locally on your machine.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| --- | |
| - hosts: localhost | |
| become: yes | |
| vars_files: | |
| - aws_credentials.yml # Contains AWS access keys and secret keys | |
| - aws_ec2_configs.yml # Contains configuration such as AWS region | |
| # Handlers are tasks that respond to a notify directive and are typically used to restart services | |
| handlers: | |
| - name: Restart HAProxy service |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| --- | |
| - name: Setup Nginx Web Server and Deploy Website | |
| hosts: localhost | |
| become: yes | |
| vars_files: | |
| - aws_credentials.yml | |
| - aws_ec2_configs.yml | |
| tasks: | |
| - name: Install Nginx | |
| yum: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| - hosts: localhost | |
| vars_files: | |
| - aws_credentials.yml | |
| - aws_ec2_configs.yml | |
| tasks: | |
| - name: Installing Python pip | |
| package: | |
| name: python3-pip | |
| state: present |