100% found this document useful (1 vote)
58 views

Azure Devs Practical Assignment

1. The document provides instructions for completing a practical assignment on Azure DevOps. Students are asked to create an Azure account if needed, then create a project in Azure DevOps with specific requirements. 2. Students then need to plan the project using Azure Boards by creating Epics, Features, User Stories and Tasks. They also create and maintain an Azure DevOps repository for their project code. 3. The final task is to set up an Azure DevOps pipeline to automate building the project code. This requires creating a new self-hosted agent on the student's machine to run the pipeline since the default agents are not available.

Uploaded by

Yashasvi Gamhewa
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
100% found this document useful (1 vote)
58 views

Azure Devs Practical Assignment

1. The document provides instructions for completing a practical assignment on Azure DevOps. Students are asked to create an Azure account if needed, then create a project in Azure DevOps with specific requirements. 2. Students then need to plan the project using Azure Boards by creating Epics, Features, User Stories and Tasks. They also create and maintain an Azure DevOps repository for their project code. 3. The final task is to set up an Azure DevOps pipeline to automate building the project code. This requires creating a new self-hosted agent on the student's machine to run the pipeline since the default agents are not available.

Uploaded by

Yashasvi Gamhewa
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 7

Contemporary Topics – Introduction to DevOps – Practical Assignment

Important: You need to complete this practical assignment within the deadline. Submission deadline is
21st October 2023 11.59 PM.

Submission: You should do all the assigned tasks in the Azure portal by the deadline. Moreover, your
project link (e.g.: https://dev.azure.com/SameerasAzureDevOpsLabStudies/2023CS255_Pathum_) should
be submitted to the given link in nLearn before the deadline. Any project without nLearn submission
will not be marked.

------------------------------------------------------------------------------------------------------------------------------------------

Assignment Scenario:

Assuming everybody has an Azure Portal Account for developers. If not, create an account using one of
your Google email accounts, following the below steps. (This is a free account, and it is required to have
this account to proceed for the practical test)

1. Go to https://dev.azure.com/ ➔ ‘Start free’ ➔ ‘Create one!’ ➔ Provide the information and


create one account.

2. Provide a proper “Organization” name which will be your Organization in the Azure Portal
account and remember the provided Organization name.
(Do not provide any credit/debit card information)

Practical Assignment

1. Create a project.
a. Project name: “your NSBM Index Number”_”first name”_”AzureDevOpsTestProject”
(i.e.: 2023CS255_Pathum_ AzureDevOpsTestProject)
b. Make it as a private project, select ‘Git’ as the Version Control and ‘Agile’ as the Work
item process.

2. Select the newly created project and ‘Invite’ to the lecturer. The invite button is available in the
top right-hand corner. Type lecturer’s email address ‘subasinghestudies@gmail.com’ in the
users drop down list and add him. This is essential since this is the only way that the lecturer can
evaluate your practical assignment.
20+ people have already created their respective organizations and invited to me as an
administrator. The rest needs to follow the same.

3. Select the newly created project and go to the ‘Project settings’ in the left-hand side bar.
a. Go to ‘Project administrators’ and ‘Add administrator’. Add lecturer’s above email
address and make him as an administrator of your project.

4. Prepare a Project Plan using Azure Boards.


a. Go to Boards ➔ Work items and create an Epic. i.e.: “My E-Commerce Web Site”
b. Create at-least 2 Features (give them proper Feature names: Search Engine…) and set
the above Epic as the parent.
c. Create at-least 2 User Stories (give them proper User Story names: Search Algorithm...)
and set the above features as the parents.
d. Create at-least 2 Tasks (give them proper Task names: SQL Data Schema...) and set the
above user stories as the parents.

5. Create and maintain Azure DevOps Repositories.


a. Go to Repos ➔ Files.
b. Clone the Azure DevOps project location to your computer.
i. Copy clone URL
ii. Open Visual Studio or any other relevant IDEs.
iii. Go to ‘Azure DevOps’ option ➔Connect to a project ➔ Add your account
(registered email).
iv. Select the dev.azure.com and your organization ➔ select the project and
connect it.
v. Provide the local repository location and clone it.
vi. Do cloning using the URL through GitHub or any other way.
vii. Go to Visual Studio ➔File ➔ New Project ➔ Select ASP.NET Core Web
Application ➔ Give Name and mapped location.
viii. Select Web Application MVC. (you can select any type of Web project)
ix. Run the application through IIS Express and see whether it loads properly.

c. Project committing, pushing and synchronization.


i. Go to Visual Studio ➔ Select Project ➔ Team Explorer ➔ Changes.
ii. Exclude Server\sqlite3 items (if available - right click ➔ ignore these local items)
iii. Put a comment and ‘Commit Staged’.
iv. Push changes to Azure DevOps server.
v. Sync changes to Azure DevOps server.
vi. Go to your Azure Project which is in the Azure DevOps server and Repos ➔ Files
and check whether your project files are available or not. If not, follow the
above steps to commit, push and sync those changes to Azure DevOps server
again.
vii. Do few minor changes to your files through Visual Studio and commit, push,
sync them to the DevOps server and verify those changes from your Azure
DevOps project.

6. Create Azure DevOps Pipeline to automate DevOps phases.


a. The purpose of this pipeline is to automate the building process of the above created
sample web application in the Azure DevOps Repos.
b. Go to Pipelines.
c. Create Pipeline. (Select ‘Azure Repos Git YAML’)
d. Select the created project repository. (It will open the YAML file automatically)
e. Configure your pipeline ➔ ASP.NET Core (.NET Framework)
f. Save and run.
g. Give Commit message & select ‘Commit directly to the master branch’.
h. Save and run.
i. Run the pipeline and check the respective JOB for any errors.
j. You may receive this error: “No hosted parallelism has been purchased or granted. To
request a free parallelism grant, please fill out the following form
https://aka.ms/azpipelines-parallelism-request”
k. We need to overcome the above issue to create a successful pipeline. Therefore, we
need to create a new Agent to run the pipeline.
l. The existing agents are not available. Therefore, we need to create a new SH agent
utilizing your PC’s resources.
m. Go to Project Settings ➔ Pipelines ➔ Agent pools and check default Agent Pools.
n. Create a new pool to have a new self-hosted agent.
o. Add Pool, select as ‘self-hosted’ pool, give a pool name and remember it.
p. Tick ‘Grant access permissions to all pipelines’ and create.
q. Select newly created pool and click on it.
r. Go to ‘Jobs’ tab and click on ‘New agent’ button.
s. Download the agent (X64 or X86 for windows).
t. Create a local folder in your PC and place this downloaded agent zip file.
u. Extract it in the folder and configure and run the self-hosted agent via command prompt
as the administrator.
v. Open command prompt as an administrator and go to the extracted agent folder
location.
w. Execute ‘config.cmd’ command in the command prompt, if error occurs, ‘config.cmd
remove’ to remove existing agent (If required, please provide the PAT)
x. Provide server URL i.e.: https://dev.azure.com/SameerasAzureDevOpsLabStudies
y. Create PAT (Personal Access Token: User settings ➔ Personal access token)
z. Provide newly created agent pool name: DevOpsStudiesProject03Pool.
(Project settings ➔ Pipelines ➔ Agent pools ➔ select newly created agent pool)
aa. Run.cmd
bb. Go to Azure DevOps project ➔ Pipelines and Edit pipeline from YAML file.
cc. Change ‘pool’ value to created pool name ‘DevOpsStudiesProject03Pool’
dd. Save and run the pipeline.
ee. Click run and check the job status again.

Server URL:
Command Prompt as an Administrator
YAML File change for the ‘pool’


Job Progress through the pipeline
Already available Organizations – Rest needs to create.

You might also like