Azure Classroom Series – 16/May/2021

Azure CLI Revisited

  • Ensure Azure CLI Tools extension is installed in Visual Studio Code
  • Lets use Azure CLI to create a ubuntu VM
    • Create a resource group
    • Create a VM and execute the commands
    • Refer Here for the changes made so far Preview
    • By default azure has a NSG rule which opens 22 port for communication
    • Now lets open 80 port for communication as we will be installing lamp stack
    • Manual Steps:
      sudo apt update
      sudo apt install apache2 -y
      sudo apt install php libapache2-mod-php php-mysql php-cli -y
      # Create a file with content <?php phpinfo(); ?>
      /var/www/html/info.php
      sudo systemctl restart apache2
    
    • Refer Here for the azure CLI
    • Exercise: Create a Centos VM from Azure CLI and install lamp stack
      sudo yum install httpd -y 
      sudo systemctl enable httpd
      sudo yum install php php-mysql php-fpm -y
      # Create a file with content <?php phpinfo(); ?>
      /var/www/html/info.php
      sudo systemctl restart httpd
    
  • Exercise 1: Lets create a windows server
  • Exercise 2: Spend some time on JMES Path Refer Here
az vm image list-publishers  #publisher
az vm image list-offer # offer
az vm image list-sku # sku
az vm image list # version
az vm image show

Leave a Reply

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

About learningthoughtsadmin