Code Monkey home page Code Monkey logo

aws_cloudtrail_logs_in_s3's Introduction


CloudTrail to check logs of user in AWS account

This project focuses on creating the S3 bucket and CloudTrail for management events using Terraform.

Table of Contents

  1. Introduction
  2. Prerequisites
  3. Usage
  4. Modules
  5. Variables
  6. Contributing

Introduction

In many AWS environments, it's crucial to have fine-grained control over resource creation permissions. This project demonstrates creation of Cloutrail (management event)and S3 bucket.

Prerequisites

Before using this project, ensure you have the following:

  • Terraform installed on your machine.
  • AWS credentials configured on your system.
  • Basic understanding of S3 , CloudTrail and Terraform.

Usage

  1. Clone this repository to your local machine:

    git clone https://github.com/vireshsolanki/aws_cloudtrail_logs_in_s3.git
  2. Navigate to the project directory:

    cd creation
  3. Initialize the Terraform configuration:

    terraform init
  4. Customize the terraform.tfvars file to specify the desired region,name.

      name = "test-cltrail"
      region = "ap-southeast-1"
    
  5. Review the Terraform configuration files to ensure they meet your requirements.

  6. Apply the changes to create the IAM policy:

    terraform apply

Modules

This project consists of the following modules:

  1. s3: Creates S3 bucket.
  2. cloudtrail: Creates CloudTrail .
    resource "aws_cloudtrail" "test-trail" {
     depends_on = [ var.test-trail-s3-policy ]
    is_multi_region_trail = true
      event_selector {
     include_management_events = true #this for the management events
     read_write_type           = "All"
      }
    

Variables

The project uses the following variables, which can be customized in the terraform.tfvars file:

  • name: It will have your CloudTrail name.
  • region: The allowed AWS region for S3 bucket.

Contributing

Contributions to this project are welcome. Feel free to submit issues, feature requests, or pull requests.

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.