GithubHelp home page GithubHelp logo

itongxiaojun / terraform Goto Github PK

View Code? Open in Web Editor NEW

This project forked from licheng019/terraform

0.0 1.0 0.0 4 KB

This is the Terraform Script for provision EC2 Instance which installed Ambari Server

HCL 100.00%

terraform's Introduction

Hadoop Infra Deployment

This project will set up a Hadoop cluster and install/configure Ambari server and agents by using Terraform.

Prerequisites

Configuration

Update the "*.tfvars" files with the right parameters:

  • Development params file: "./environments/development/variables/*.tfvars"
  • Production params file: "./environments/production/variables/*.tfvars"

Set-up and run

  • Initialization
cd ./hadoop_dev
terraform init
  • Plan/Deploy/Destroy development environment:
# PLAN
terraform plan \
-state="./environments/development/dev.state" \
-var-file="./environments/development/variables/global.tfvars" \
-var-file="./environments/development/variables/ambari_agent.tfvars" \
-var-file="./environments/development/variables/ambari_server.tfvars"

# APPLY 
terraform apply \
-state="./environments/development/dev.state" \
-var-file="./environments/development/variables/global.tfvars" \
-var-file="./environments/development/variables/ambari_agent.tfvars" \
-var-file="./environments/development/variables/ambari_server.tfvars"

# DESTROY
terraform destroy -force \
-state="./environments/development/dev.state" \
-var-file="./environments/development/variables/global.tfvars" \
-var-file="./environments/development/variables/ambari_agent.tfvars" \
-var-file="./environments/development/variables/ambari_server.tfvars"
  • Plan/Deploy/Destroy production environment:
# PLAN
terraform plan \
-state="./environments/production/prod.state" \
-var-file="./environments/production/variables/global.tfvars" \
-var-file="./environments/production/variables/ambari_agent.tfvars" \
-var-file="./environments/production/variables/ambari_server.tfvars"

# APPLY 
terraform apply \
-state="./environments/production/prod.state" \
-var-file="./environments/production/variables/global.tfvars" \
-var-file="./environments/production/variables/ambari_agent.tfvars" \
-var-file="./environments/production/variables/ambari_server.tfvars"

# DESTROY
terraform destroy -force \
-state="./environments/production/prod.state" \
-var-file="./environments/production/variables/global.tfvars" \
-var-file="./environments/production/variables/ambari_agent.tfvars" \
-var-file="./environments/production/variables/ambari_server.tfvars"

terraform's People

Contributors

licheng019 avatar

Watchers

James Cloos 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.