File tree Expand file tree Collapse file tree 1 file changed +8
-7
lines changed
Expand file tree Collapse file tree 1 file changed +8
-7
lines changed Original file line number Diff line number Diff line change 99
1010AZURE_CLIENT_ID=$1
1111CREDENTIAL_NAME=" GitHubActionsFederatedCredential"
12+ BRANCH_NAME=" dev"
1213
1314# Check if the federated credential already exists
1415echo " Checking if federated credential '$CREDENTIAL_NAME ' already exists..."
@@ -19,14 +20,14 @@ if [ "$(echo $EXISTING_CREDENTIAL | jq 'length')" -gt "0" ]; then
1920else
2021 echo " Creating federated credential '$CREDENTIAL_NAME '..."
2122 az ad app federated-credential create --id $AZURE_CLIENT_ID \
22- --parameters ' {
23- "name": "GitHubActionsFederatedCredential",
24- "issuer": "https://token.actions.githubusercontent.com",
25- "subject": "repo:nullchimp/ai-agent:ref:refs/heads/RAG ",
26- "audiences": [
27- "api://AzureADTokenExchange"
23+ --parameters " {
24+ \ " name\ " : \ " GitHubActionsFederatedCredential\ " ,
25+ \ " issuer\ " : \ " https://token.actions.githubusercontent.com\ " ,
26+ \ " subject\ " : \ " repo:nullchimp/ai-agent:ref:refs/heads/$BRANCH_NAME \ " ,
27+ \ " audiences\ " : [
28+ \ " api://AzureADTokenExchange\ "
2829 ]
29- }'
30+ }"
3031
3132 if [ $? -eq 0 ]; then
3233 echo " Federated credential created successfully."
You can’t perform that action at this time.
0 commit comments