Skip to content

Commit 4955540

Browse files
Merge pull request #217 from microsoft/psl-Pipelinefix
fix: Remove createdby from pipeline and changes bicep logic for createdBy tag
2 parents ab638e2 + 0c967d7 commit 4955540

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

.github/workflows/deploy.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ jobs:
135135
aiDeploymentsLocation="eastus" \
136136
useWafAlignedArchitecture=false \
137137
capacity=${{ env.GPT_MIN_CAPACITY }} \
138-
imageVersion="${IMAGE_TAG}" \
138+
imageVersion="${IMAGE_TAG}"\
139139
createdBy="Pipeline"
140140
- name: Assign Contributor role to Service Principal
141141
if: always()

infra/main.bicep

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -132,8 +132,9 @@ var modelDeployment = {
132132

133133
var abbrs = loadJsonContent('./abbreviations.json')
134134

135-
@description('Optional created by user name')
136-
param createdBy string = empty(deployer().userPrincipalName) ? '' : split(deployer().userPrincipalName, '@')[0]
135+
@description('Tag, Created by user name')
136+
param createdBy string = contains(deployer(), 'userPrincipalName')? split(deployer().userPrincipalName, '@')[0]: deployer().objectId
137+
137138

138139
// ========== Resource Group Tag ========== //
139140
resource resourceGroupTags 'Microsoft.Resources/tags@2021-04-01' = {

0 commit comments

Comments
 (0)