- 
      
- 
        Save akhy/7d7f0150214be1c9431b to your computer and use it in GitHub Desktop. 
    ansible task for android sdk
  
        
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | export PATH="/opt/android-sdk-linux/tools:${PATH}" | 
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | --- | |
| - name: Install packages to install android sdk | |
| yum: name={{ item }} state=installed | |
| with_items: | |
| - glibc.i686 | |
| - libstdc++.i686 | |
| - glibc-devel.i686 | |
| - zlib.i686 | |
| - zlib-devel.i686 | |
| - ncurses-devel.i686 | |
| - libX11-devel.i686 | |
| - libXrender.i686 | |
| - ld-linux.so.2 | |
| - name: Install Java | |
| yum: name={{ item }} state=installed | |
| with_items: | |
| - java-1.7.0-openjdk | |
| - java-1.7.0-openjdk-devel | |
| - name: Download sdk tools | |
| get_url: > | |
| url=http://dl.google.com/android/android-sdk_r23.0.2-linux.tgz | |
| dest=/opt/android-sdk_r23.0.2-linux.tar.gz | |
| register: sdk_file | |
| - name: Unarchive sdk tools | |
| command: > | |
| tar xzf {{ sdk_file.dest }} | |
| creates=/opt/android-sdk-linux | |
| chdir=/opt | |
| - name: Set envs for android sdk | |
| copy: > | |
| src=android.sh | |
| dest=/etc/profile.d/android.sh | |
| - name: Install Android SDKs | |
| shell: echo y | android update sdk -u -a -t "{{ item }}" | |
| with_items: | |
| - tools | |
| - platform-tools | |
| - build-tools-19.1.0 | |
| - android-20 | |
| - android-19 | |
| - android-18 | |
| - android-17 | |
| - extra-android-support | |
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment