Jenkins giving The SDK Directory doesn't exist

This smells like a permission problem. You might have given permission to the sdk-dir but not the parent directory.


In my situation, it happened because file

local.properties

had been added to .gitignore

(I assemble from remote)


I just want to say how we fixed this problem in our project. It may help someone.

The working directory of our Jenkins is under "/User/shared", and our SDK is under "/User/foo"

We tried to give user foo and everyone permission to the SDK folder and its parent folders, but it did not work.

Then we installed SDK under /user/Shared/Jenkins/Library/Android/SDK via Android SDK Manager, and gave user foo and everyone permission to the new SDK folder and its parent folders. Also, we changed the SDK Path to new in Jenkins project configuration. Then it works.