scb-tomasmortensen / vsix-argocd

Other
3 stars 4 forks source link

Error 'permission denied' to specific application #2

Open karl18 opened 1 year ago

karl18 commented 1 year ago

Hi, I've got an issue when I define some App to make the CICD pipeline sync with:

Service Endoint URL: https://argocd.flaschenpost.de/
Service Endpoint Scheme: Token
##[debug]argocdCommand=sync
Selected command: sync
##[debug]argocdApplication={ Value : "webshop-canary", DisplayValue : "webshop-canary" }
Selected Application: { Value : "webshop-canary", DisplayValue : "webshop-canary" }
Dry Run: false
##[debug][POST][https://argocd.flaschenpost.de/api/v1/applications/{](https://argocd.flaschenpost.de/api/v1/applications/%7B) Value : "webshop-canary", DisplayValue : "webshop-canary" }/sync
##[debug]{"statusCode":403,"statusMessage":"Forbidden","headers":{"date":"Mon, 24 Jul 2023 22:55:21 GMT","content-type":"application/json","content-length":"68","connection":"close","strict-transport-security":"max-age=15724800; includeSubDomains","cf-cache-status":"DYNAMIC","server":"cloudflare","cf-ray":"7ebfc00e5a8c06bc-AMS"},"body":{"error":"permission denied","code":7,"message":"permission denied"}}
WebResponse {
  statusCode: 403,
  statusMessage: 'Forbidden',
  headers:
   { date: 'Mon, 24 Jul 2023 22:55:21 GMT',
     'content-type': 'application/json',
     'content-length': '68',
     connection: 'close',
     'strict-transport-security': 'max-age=15724800; includeSubDomains',
     'cf-cache-status': 'DYNAMIC',
     server: 'cloudflare',
     'cf-ray': '7ebfc00e5a8c06bc-AMS' },
  body:
   { error: 'permission denied',
     code: 7,
     message: 'permission denied' } }
##[debug]task result: Failed
##[error]Argo CD operation failed.

This is basically coming from azure DevOps agent. I would like some support to know exactly which permission or role do I need to specify in ARGOCD to the running agent, or how could I overcome this issue ?

Basically it's erroring when trying to access: https://argocd.flaschenpost.de/api/v1/applications/%7B

Screenshot 2023-07-25 at 00 54 34 Screenshot 2023-07-25 at 00 54 41 Screenshot 2023-07-25 at 00 54 47

Although I see the apps when I try to add the task in azure pipelines:

Screenshot 2023-07-25 at 11 01 33

I appreciate your support! Thanks in Advance

karl18 commented 1 year ago

@scb-tomasmortensen

Edd-1234 commented 4 months ago

@karl18 I am seeing the same issue, did you find a fix? Thanks