Set Up and Manage a Secure Azure DevOps Repository
Requirements
New: The Nautilus DevOps Team has received a request from the Development Team to set up a new repository for better code management. They need a secure way to access the repository using SSH.
Create an Azure DevOps repository named datacenter-repo in the project name datacenter-project. Add the root user's SSH public key from azure-client host to the Azure DevOps SSH keys. Create an SSH config under /root/.ssh/config on azure-client host and make changes to authenticate with the created repository. Clone the new repository on azure-client host under /root. Add the contents of /root/pyapp directory to this repository, then add, commit, and push the changes to the repository. You might need to set the git user and email to commit your code; you can use any email ID and user name for that. Please use the same credentials provided for logging into the Azure portal to log in to the Azure DevOps portal.
Old: The Nautilus DevOps Team has received a request from the Development Team to set up a new repository for better code management. They need a secure way to access the repository using SSH.
Create an Azure DevOps repository named datacenter-repo in the project name datacenter-project. Add the root user's SSH public key from azure-client host to the Azure DevOps SSH keys. Create an SSH config under /root/.ssh/config on azure-client host and make changes to authenticate with the created repository. Clone the new repository on azure-client host under /root. Add the contents of /root/pyapp directory to this repository, then add, commit, and push the changes to the repository. You might need to set the git user and email to commit your code; you can use any email ID and user name for that. Please use the same credentials provided for logging into the Azure portal to log in to the Azure DevOps portal.
Use below given Azure DevOps Credentials: (You can run the showcreds command on azure-client host to retrieve these credentials)
| Portal URL | Azure Devops |
|---|---|
| Organization | devops_org |
The solution can be implemented using both the Azure Cloud Console and the Azure CLI. This document outlines the CLI-based approach to accomplish these tasks. It is recommended to first explore the Azure Cloud Console for hands-on experience and a practical understanding of the process before utilizing the CLI approach, unless specifically instructed otherwise.
Steps