简体   繁体   中英

Android build failed in jenkins

I am building an android application in jenkins. but it's saying The SDK directory ' /var/lib/jenkins/android-sdk' does not exist.

I have set the android sdk path My andoid sdk configuration in jenkins

Kindly help me out. Thnaks in advance :)

You can follow below steps to achieve this.

  1. Go to Jenkins > Manage Jenkins > Configure System

  2. Check "Environment variables"

  3. add name: ANDROID_HOME, value -> your complete Android SDK dir path

  4. click "add"

  5. SCROLL DOWN CLICK SAVE

or

I fixed it using:

  1. Copy your Android folder \\Users{yourUser}\\Library\\Android\\

  2. Paste in the folder \\Users\\Shared\\Jenkins\\Library

  3. Go to Jenkins -> Manage Jenkins -> Configure System

  4. Check "Environment variables"

  5. add name: ANDROID_HOME, value -> \\Users\\Shared\\Jenkins\\Library\\Android\\sdk

  6. Add

  7. Save

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM