DevOps Classroom Series – 26/Oct/2021

Scenario of an Organization (LT)

  • LT is working on a project towards Health Care Software MRS
  • The architecture of the project Preview
  • To work on this project we have 3 developer teams
    • Front end
    • django/mrs developers
    • java/radiology developers
  • We also have a
    • QA Team
  • LT according to their QA policy wants to build
    • Day build environment (Component test)
    • System Test (Nightly build)
    • Performance test (Weekly build)
    • Customer Demo (Release build) Preview
  • So doing the deployment of the applications manually is no longer the option.
  • LT already has servers available for all the environments, We need a solution to deploy the applications and/or configure the applications so that stake holders can use it.

Possible Solutions:

  • Lets take the following analogy Preview
  • Now lets apply the same to scripting vs configuration management Preview
  • Example:
    • Install apache server on ubuntu
      • shell/bash: sudo apt update && sudo apt install apache2 -y
      • configuration management: we will be writing in some syntax which implies Ensure apache2 is installed
    • Create a file at /usr/share/ltmrs/info.config
      • shell/bash: touch /usr/share/ltmrs/info.config or echo "" > /usr/share/ltmrs/info.config
      • configuration management: we will be writing in some syntax which implies Ensure file is present at /usr/share/ltmrs/info.config
  • Configuration management are designed to be idempotent. Idempotance is a property which ensures you will get the same result irrespective of how many time you executed the script.
  • If we use shell/Powershell scripts the developer of the script needs to write conditional statements almost for every step to ensure idempotance which becomes difficult to read & maintain.
  • With Configuration management tools we use declarative approach to automate where we will mention our desired state (Ensure apache2 is installed), whereas in shell scripts we follow procedural approach.

Exercise:

  1. Azure Free tier Account Creation Refer Here
  2. AWS Free tier Account Creation Refer Here
  3. Necessary Software Installation Refer Here
  4. For Windows 10 and above configure Windows Terminal Refer Here
  5. Create an account in manage.chef.io Refer Here

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

About learningthoughtsadmin