Creating Azure DevOps Repos for GitOps
June 10, 2019 ยท View on GitHub
Prerequistes
- Install the Azure CLI DevOps Extension
Setup
1. Create a New Project in Azure DevOps using the CLI
$ az devops project create -n $PROJECT_NAME
2. Create a Personal Access Token
- Click your profile name in the upper right corner.
- Click the
Securitysubmenu. - Choose
Personal Access Tokenson the left window menu. - Click
+ New Tokens
- Make sure your Personal Access Token (PAT) has appropriate permissions to read and write Azure DevOps builds and code.

3. Create High Level Definition and Manifest Repositories
- Create high level definition (HLD) and manifest repositories in your new ADO project using the command line. In the below,
$HLD_REPO_NAMEand$MANIFEST_REPO_NAMEcorrespond to the name of the each of the repos respectively.
$ az repos create --name $HLD_REPO_NAME
$ az repos create --name $MANIFEST_REPO_NAME
- (optionally) If you are using our sample HLD repo, import it with the following command:
$ az repos import create --git-source-url $SAMPLE_HLD_REPO_PATH --repository $HLD_REPO_NAME
Make sure you have an azure-pipelines.yml file at the root of your repository, as we will use this later to setup the build rules in Azure Devops.