Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 27 additions & 0 deletions VM.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# get resource group name

read -p 'resource-group name: ' resourceGroupName

# get VM

read -p 'VM name: ' vmName

# get username

read -p 'username: ' username

# create resource gource group

az group create --name $resourceGroupName --location eastus


# Create VM

az vm create \
--resource-group $resourceGroupName \
--name $vmName \
--image UbuntuLTS \
--admin-username $username \
--ssh-key-values ~/.ssh/id_rsa.pub


10 changes: 8 additions & 2 deletions readme.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,13 @@
# Learning Bash Scripting

## Introduction
## Module-1
- Introduction

### Using comments and variables
## Module-2
- Using comments and variables

## Module-3
- Read User's Input

## Module-3.1
- Setting up VM
21 changes: 20 additions & 1 deletion script.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,23 @@ echo This is my course $course

founded='Unilorin was founded in the year 1975'

echo This is my founded $founded
echo This is my founded $founded

read -p 'Entered name: ' name

read -p 'Enter school: ' school

read -p 'Enter course: ' course

read -p 'Enter result: ' result

echo 'my name is' $name 'my school is' $school 'my result is' $result

read -p 'username for https://github.com: ' username

read -p 'password for https://'$username'@github.com: ' password

echo 'this is the' $username tand $password