Skip to content

Commit

Permalink
Add product Id input and fix upload policy step
Browse files Browse the repository at this point in the history
  • Loading branch information
ebronson68 committed Jul 11, 2023
1 parent ac7563c commit c0d3f4c
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions .github/workflows/b2c-build-and-deploy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,10 @@ on:
required: false
type: string
description: "URL of the B2C Product."
azureB2CProductId:
required: true
type: string
description: "ID of the B2C product."
secrets:
azureCredentials:
required: true
Expand Down Expand Up @@ -100,23 +104,19 @@ jobs:
- name: Build Policies
shell: pwsh
run: |
$Environment = "${{ inputs.environment }}"
$ProductName = "${{ inputs.azureB2CProductName }}".Replace("-","").Replace("the","")
yarn config set product $ProductName
yarn config set environment $Environment
yarn build
yarn build:${{ inputs.environment }}
- name: "Upload TrustFrameworkBase Policy"
uses: azure-ad-b2c/deploy-trustframework-policy@v5.3
- name: Upload TrustFrameworkBase Policy
uses: azure-ad-b2c/deploy-trustframework-policy@v5
with:
folder: "./dist/${{ inputs.azureB2CProductName }}/custom-policies"
files: "B2C_1A_TPS_SIGNINSIGNOUT_BASE.xml,B2C_1A_TPS_SIGNINSIGNOUT_EXTENSIONS.xml,B2C_1A_TPS_SIGNINSIGNOUT_POLICIES.xml,B2C_1A_TPS_IMPERSONATION.xml"
files: "B2C_1A_${{ inputs.azureB2CProductId }}_SIGNINSIGNOUT_BASE.xml,B2C_1A_${{ inputs.azureB2CProductId }}_SIGNINSIGNOUT_EXTENSIONS.xml,B2C_1A_${{ inputs.azureB2CProductId }}_SIGNINSIGNOUT_POLICIES.xml,B2C_1A_${{ inputs.azureB2CProductId }}_IMPERSONATION.xml"
tenant: ${{ inputs.azureB2CDomain }}
clientId: ${{ secrets.azureB2CClientId }}
clientSecret: ${{ secrets.azureB2CClientSecret }}

- name: Upload Auth Assets
uses: azure/powershell@v1.2.0
uses: azure/powershell@v1
with:
inlineScript: |
$BasePath = Get-Location
Expand Down

0 comments on commit c0d3f4c

Please sign in to comment.