Giter Site home page Giter Site logo

ecs-cft-apitest's Introduction

Project Overview

Defines a scheduled Fargate task that runs once per minute. The Fargate task must print a Random Useless Fact obtained from this public API: https://uselessfacts.jsph.pl/api/v2/facts/random to stdout. Only the "text" portion of the API response needs to be printed.

  • The Fargate task container must be configured to send stdout to CloudWatch Logs. The reviewer of your submission will check CloudWatch Logs for the expected output.
  • The CloudFormation stack should provide the CloudWatch Log Group name associated with the previous item in it's Outputs.

Architecture Design

AWS CloudFormation + ECS Tasks cron-like schedule + Cloudwtach Logging to test public API

CloudFormation Template

link of the template file: https://github.com/abhishekonteddu/ECS-CFT-APITEST/blob/main/cloudformationtemplate.yml

The CloudFormation template includes the following resources:

it uses the VPC, subnets create new role and policy for execution the ecs fargate, cluster, scheduled tasks and create cloudwatch resources for logs creates the security-group to open the port 80

Deployment Guide

  1. The deployment guide includes the following steps: Go the Cloudformation and upload the cloudformation template and select the subnet and vpc next click on the next ,select the check and click submit wait for the stack to be completed
  2. if we need to change the cpu and memory of ecs we can change in parameter include cloudwatch logs retain peroid in parameters

Testing Plan

  1. go and check the ecs culster there will be scheduled task check cron expression which is going to start the task every one minute
  2. after the scheduled task is created it creates very task per minute you can check it in the task section in cluster
  3. check the cloudwatch where the log group name is task-LogsGroup where you have one separate logstream for everytask check the log you will display the text of the url
  4. check the task in ecs is every one minute new container is running or not

Screenshots

alt text

alt text

alt text

alt text

alt text

ecs-cft-apitest's People

Contributors

abhishekonteddu avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.