0

I am using 'run a bash script' task in my azure yaml pipeline. I need to access service connection ( docker connection) within the script so I can login to docker & jfrog and logout multiple times ( without having to use variables or variable groups) .

How can I achieve this? Appreciate your suggestions & help in advance

gmpy1990
  • 55
  • 9

1 Answers1

0

It depends on the way that you used to access the service connection in your bash. If you use the System.AccessToken, the permission of the token is corresponding to the Project Collection Build Service ({OrgName}) or {Project Name} Build Service ({Org Name}), depending on the job authorization scope.

Then add the specific identity to the Security of the service connection.

enter image description here

enter image description here

If you use other ways to auth, you can also add the corresponding identity with the permission you want.

Joy Wang
  • 39,905
  • 3
  • 30
  • 54