Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add githubAccount and githubBranch parameters to azure-pipelines.yml #2383

Merged
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
24 changes: 22 additions & 2 deletions azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,23 @@ parameters:
displayName: 'Azure Subscription'
type: string
default: 'Azure Arc Jumpstart Develop(98a19988-5c3d-4824-a685-f5cf12ae5c19)'
- name: githubAccount
displayName: 'githubAccount'
type: string
default: 'microsoft'
- name: githubBranch
displayName: 'githubBranch'
type: string
default: 'arcbox_3.0'

variables:
- group: 'integration-tests'
- name: ResourceGroupName
value: ${{parameters.ResourceGroupName}}
- name: githubAccount
value: ${{parameters.githubAccount}}
- name: githubBranch
value: ${{parameters.githubBranch}}

stages:
- stage: 'ArcBox_deployment'
Expand Down Expand Up @@ -56,6 +68,14 @@ stages:
azurePowerShellVersion: 'LatestVersion'
Inline: |
Write-Host "Deploying to $(ResourceGroupName)"
$githubAccount = $(githubAccount)
$githubBranch = $(githubBranch)
if ($githubAccount -ne "microsoft") {
Write-Host "Checking out $githubAccount/$githubBranch"
git remote add upstream [email protected]:$($githubAccount)/azure_arc.git
git fetch upstream
git checkout -b $githubBranch upstream/$githubBranch
}
New-AzResourceGroupDeployment -Name ArcBox `
-ResourceGroupName $(ResourceGroupName) `
-TemplateFile azure_jumpstart_arcbox/bicep/main.bicep `
Expand All @@ -69,8 +89,8 @@ stages:
logAnalyticsWorkspaceName = "arcbox-la" ; `
flavor = "ITPro" ; `
deployBastion = $false ; `
githubAccount = "microsoft" ; `
githubBranch = "arcbox_3.0" ; `
githubAccount = $githubAccount ; `
githubBranch = $githubBranch ; `
vmAutologon = $true ; `
rdpPort = "3389" `
}
Expand Down
Loading