Giter Site home page Giter Site logo

training's Introduction

Release

drawing

Detailed prerequisites and instructions for spinning DEV/STAGE/PROD environments

DEV environment

Prerequisites
  • Install Docker (version 19.03.xx or higher)
  • Install Docker Compose (version 1.25.5 or higher)
  • AWS account
  • AWS Profile
  • Create an envfile '.env.dev' from the example '.env.dev.example'
  • Chrome - Allows requests to localhost over HTTPS even when an invalid certificate is presented. `chrome://flags/#allow-insecure-localhost`
Spin DEV environment Execute the following commands:
  1. make up
  2. Browse: https://localhost:8443
Teardown DEV environment Execute the following commands:
  1. ./build/build.sh dev
  2. source .env.dev
  3. docker run --rm -v /var/run/docker.sock:/var/run/docker.sock ${NAMESPACE}/spinner:latest ./spin-docker.py --action destroy
  4. docker image prune -af
  5. docker volume prune -f

STAGE environment

Prerequisites
  • Dockerhub account
  • AWS account
  • AWS Profile
  • Terraform
  • Docker
  • Docker Compose
  • AWS ~/.aws or %UserProfile%\.aws folder
  • subnet ID
  • Security Group with inbound ports for SSH (22), HTTP (80), HTTPS (443), and 8200
  • AWS S3 Bucket
  • Create an envfile '.env.stage' from the example '.env.stage.example'
Spin STAGE environment

Execute the following:

  1. ./build/build.sh stage
  2. source .env.stage
  3. terraform -chdir=deploy init
  4. terraform -chdir=deploy apply --var-file=aws-stage.tfvars
  5. docker run --rm -v $HOME/.aws:/root/.aws -v /var/run/docker.sock:/var/run/docker.sock ${NAMESPACE}/spinner:latest ./spin-docker.py --environment $ENVIRONMENT
  6. Locate the EC2 instance Public DNS: AWS Consule->EC2->Insance->Public DNS (IPv4)
  7. Browse
Teardown STAGE environment

Execute the following:

  1. ./build/build.sh stage
  2. docker run --rm -v ~/.aws:/root/.aws -v /var/run/docker.sock:/var/run/docker.sock ${NAMESPACE}/spinner:latest ./spin-docker.py --environment $ENVIRONMENT --action destroy
  3. docker image prune -af

PROD environment

Prerequisites
  • Dockerhub account
  • AWS account
  • AWS Profile
  • AWS ~/.aws or %UserProfile%\.aws folder
  • keypair
  • subnet ID
  • Security Group with inbound ports for SSH (22), HTTP (80), HTTPS (443), and 8200
  • AWS S3 Bucket
  • Elastic IP Address (EIP)
  • Create an envfile '.env.prod' from the example '.env.prod.example'
Teardown PROD environment

Execute the following:

  1. ./build/build.sh prod
  2. source .env.prod
  3. docker run --rm -v ~/.aws:/root/.aws -v /var/run/docker.sock:/var/run/docker.sock ${NAMESPACE}/spinner:latest ./spin-docker.py --environment $ENVIRONMENT --action destroy
  4. docker image prune -af
Spin PROD environment

Execute the following:

  1. ./build/build.sh prod
  2. terraform -chdir=deploy init
  3. terraform apply -chdir=deploy --var-file=aws-prod.tfvars
  4. docker run --rm -v $HOME/.aws:/root/.aws -v /var/run/docker.sock:/var/run/docker.sock ${NAMESPACE}/spinner:latest ./spin-docker.py --environment $ENVIRONMENT
  5. Browse www.devopsloft.org

training's People

Contributors

abedsarsur avatar balex3000 avatar daniellitvak avatar lmilbaum avatar maoryadin avatar noamgu avatar perigorn avatar royzlevy avatar shimitanaka avatar shlomizi avatar yishaiz avatar yosefrow avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

training's Issues

README file

Update the content of this repo to reflect what it really is

[coding party] git workshop #1, challenge #1

Add instructions on how to fork the devopsloft/training repo in the README.md file.

The file to update:
training/git/1/1/README.md

Verify that GitHub renders the content properly

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.