You do not have permissions to access this api endpoint(api/instances)

Invoke-WebRequest: /var/opt/morpheus/morpheus-local/repo/git/fe07c1123d02a38b447b555704bd98bc/morpheus/approvals/getPendingApprovals.ps1:64
Line |
  64 |  … Instance = (Invoke-WebRequest -Method Get -Uri ($MorphURL + 'api/inst …
     |                ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
     | {"success":false,"msg":"You do not have permissions to access this api
     | endpoint"}

We just upgraded our Morpheus to 6.0.4. We are having issue executing this. Running the command manually from Morpheus server or other server works.

Here is the exact command:

        $Instance = (Invoke-WebRequest -Method Get -Uri ($MorphURL + 'api/instances/' + $($approval.approvalItems[0].reference.id)) -SkipCertificateCheck -Headers $Header).content | ConvertFrom-Json | Select-Object -ExpandProperty instance

I was trying to duplicate the same message(“You do not have permissions to access this api endpoint”) by changing the token and manipulating the instance ID, wasn’t able to. I’m assuming that message is coming from Morpheus.

Are there any instances in the instance list that are waiting for internal approval? If so, this is a known issue and the fix will be available in 6.0.5.

By the error message, it does look like there are instances that are pending approval.

Invoke-WebRequest: /var/opt/morpheus/morpheus-local/repo/git/fe07c1123d02a38b447b555704bd98bc/morpheus/approvals/getPendingApprovals.ps1:64
Line |
  64 |  … Instance = (Invoke-WebRequest -Method Get -Uri ($MorphURL + 'api/inst …
     |                ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
     | {"success":false,"msg":"You do not have permissions to access this api
     | endpoint"}

Thanks @dgaharwar !

We have thoroughly confirmed and verified that this is indeed the situation. We made the decision to upgrade to version 6.0.4 LTS, under the assumption that LTS signifies it as the most stable version. Regrettably, that wasn’t the case in our production environment.

I apologize for any inconvenience you experienced with the upgrade to version 6.0.4 LTS. While LTS versions are generally considered more stable and suitable for production environments, there can still be unexpected issues that arise in specific configurations or setups.

It’s always important to carefully evaluate and test any feature/functionality before deploying them to production to minimize the impact on your systems and users.

Was this tested in your test/dev environment before upgrading to 6.0.4?

Thanks
Deepti

Hey @dgaharwar

Indeed, we have a UAT server where we conducted comprehensive testing. However, regrettably, we overlooked this particular issue and did not anticipate its occurrence.

And any time estimate for 6.0.5 release date?

Thanks!

Dong