sonarcloud-github-action icon indicating copy to clipboard operation
sonarcloud-github-action copied to clipboard

Update cleanup.sh: Added input validation for projectBaseDir

Open fdx-alberto-miranda opened this issue 1 year ago • 3 comments
trafficstars

Added input validation for PROJECTBASEDIR

If you don't set the input projectBaseDir it's causing an error like this:

Error: Access to the path '/home/runner/work/_temp/_github_workflow/event.json' is denied.

fdx-alberto-miranda avatar Dec 12 '23 00:12 fdx-alberto-miranda

Not specifying projectBaseDir doesn't necessarily cause the above error. I think the real issue is somewhere else. FYI, we are about to release a separate fix for this.

cody-simms-sonarsource avatar Dec 12 '23 21:12 cody-simms-sonarsource

@cody-simms-sonarsource can you share a bit more about this issue? defining PROJECTBASEDIR is indeed not fixing the problem for me

gnuton avatar Feb 06 '24 16:02 gnuton

@gnuton The issue stems from the fact that permissions on files created in the docker image do not correctly map to users or groups on the host, which can cause "access denied" errors when deleting those files. As you mentioned, this has nothing to do with specifying a defining a PROJECTBASEDIR.

cody-simms-sonarsource avatar Feb 06 '24 17:02 cody-simms-sonarsource

Thanks for your contribution @fdx-alberto-miranda ! As Cody mentioned, the fix proposed here doesn't relate to the issue you had. In addition, we recently released a change to make this property optional, therefore, I'm closing this PR.