Giter VIP home page Giter VIP logo

week6-terraform-ansible's Introduction

week6-terraform-ansible

image

Configuration:

  • Clone this reposetory
  • Install Terraform
  • Use azurerm as a provider.
  • Run in the cli "terraform init"
  • Create 2 workspaces Production and Staging and select one
  • For Production workspace run in the cli terraform apply -var-file production.tfvars -auto-approve
  • For Staging workspace run in the cli terraform apply -var-file staging.tfvars -auto-approve

in production.tfvars and staging.tfvars you have those variables and you will need to fill the blanks one

resource_group_name = "staging"
location            = "eastus"

sku                             = "Standard_F2"
num_of_instances                = 2
admin_username                  = ""
admin_password                  = ""
postgres_administrator_login    = "postgres"
postgres_administrator_password = ""
myIP_Address                    = "" / your IP address

okta_org_url   = ""
okta_secret    = ""
okta_client_id = ""
okta_key       = ""

the only thing thats diffrent are num_of_instances, in production we have 3 instances and in staging 2 instances (Goal 4)

okta_key is used to fill automatic your okta app sign-in redirect URIs. the get key go to your okta portal. on the left menu choose Security -> API click on the Tokens tab and click Create Token

Goals:

  1. Use Terraform to provision the infrastructure.
  2. Use Ansible to deploy the NodeWeightTracker application. - https://github.com/TamirAtia/ansible-bootcamp
  3. Create two environments: Staging and Production
  4. Both environments must be identical except for the size of the vms (production ones must be larger).
  5. Using a Managed Postgresql

Terraform Installing

We have to use a terraform platform and let's get practice first with a simple hands on manual

https://learn.hashicorp.com/tutorials/terraform/install-cli?in=terraform/azure-get-started

https://docs.microsoft.com/en-us/azure/developer/terraform/create-linux-virtual-machine-with-infrastructure

then we will build our app environment using infrastructure as a code (IaaC) in Azure cloud

https://azure.microsoft.com/en-us/account/

week6-terraform-ansible's People

Contributors

tamiratia avatar

Watchers

 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.