README.md
1Docker
2======
3
4Docker files to ease working with the Android SDK/NDK and SKQP.
5
6android-skqp
7-------------
8
9This image has an Android emulator, the Android SDK and NDK installed on it.
10Additionally, it has the dependencies needed to build SKQP - Clang, python, ninja.
11
12It gets manually pushed anytime there's an update to the Dockerfile or relevant
13installed libraries.
14
15 # This will pause after the "Accept? (y/N)" prompt as it installs the NDK;
16 # you do not need to hit "y".
17 docker build -t android-skqp ./android-skqp/
18 # use v2, v3 for respins; see http://gcr.io/skia-public/android-skqp for
19 # latest version
20 ANDROID_SDK_VERSION="8.1_v1"
21 docker tag android-skqp gcr.io/skia-public/android-skqp:$ANDROID_SDK_VERSION
22 docker push gcr.io/skia-public/android-skqp:$ANDROID_SDK_VERSION
23
24
25For testing the image locally, the following flow can be helpful:
26
27 docker build -t android-skqp ./android-skqp/
28
29 # start an emulator
30 docker run --privileged -d --name android_em \
31 -e DEVICE="Samsung Galaxy S6" \
32 -v $SKIA_ROOT:/SRC \
33 -v $SKIA_ROOT/out/skqp:/OUT \
34 android-skqp
35
36 # attach to that emulator
37 docker exec -it android_em /bin/bash
38
39 # Compile SKQP
40 docker run -it --rm -w /SRC/infra/skqp \
41 -v $SKIA_ROOT:/SRC \
42 android-skqp ./build_apk.sh
43
44 # Run SKQP (can't mount anything with -v here, must do it on
45 # original docker run)
46 docker exec -it android_em /SRC/infra/skqp/run_skqp.sh
47
48 # Cleanup
49 docker kill android_em
50 docker rm android_em
51