From 01e83e2fbac8fc55fe908aceed4321a1d358481a Mon Sep 17 00:00:00 2001 From: Artyom Shalkhakov Date: Wed, 10 Jan 2018 12:48:58 +0600 Subject: [PATCH 1/3] Use android SDK v23, improving xamarin.android file lookup --- Dockerfile | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/Dockerfile b/Dockerfile index 7667441..750a34c 100644 --- a/Dockerfile +++ b/Dockerfile @@ -3,7 +3,7 @@ FROM fedora:25 RUN dnf install gnupg wget dnf-plugins-core -y \ && rpm --import "http://keyserver.ubuntu.com/pks/lookup?op=get&search=0x3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF" \ && dnf config-manager --add-repo http://download.mono-project.com/repo/centos7/ \ - && dnf install libzip mono-devel nuget msbuild referenceassemblies-pcl -y \ + && dnf install libzip bzip2 bzip2-libs mono-devel nuget msbuild referenceassemblies-pcl -y \ && dnf clean all RUN dnf install curl unzip java-1.8.0-openjdk-headless java-1.8.0-openjdk-devel -y && \ @@ -15,14 +15,17 @@ RUN mkdir -p /android/sdk && \ rm sdk-tools-linux-3859397.zip RUN cd /android/sdk && \ - yes | ./tools/bin/sdkmanager 'build-tools;25.0.3' platform-tools 'platforms;android-25' 'ndk-bundle' - -RUN curl -L https://jenkins.mono-project.com/view/Xamarin.Android/job/xamarin-android-linux/lastSuccessfulBuild/Azure/processDownloadRequest/xamarin-android/oss-xamarin.android_v7.3.99.59_Linux-x86_64_master_4799ea2.zip \ - -o oss-xamarin.android_v7.3.99.59_Linux-x86_64_master_4799ea2.zip && \ - unzip -q oss-xamarin.android_v7.3.99.59_Linux-x86_64_master_4799ea2.zip && \ - mv oss-xamarin.android_v7.3.99.59_Linux-x86_64_master_4799ea2 /android/xamarin && \ + yes | ./tools/bin/sdkmanager --licenses && \ + ./tools/bin/sdkmanager 'build-tools;23.0.3' platform-tools 'platforms;android-23' 'ndk-bundle' + +RUN dnf install lynx -y +RUN lynx listonly -dump https://jenkins.mono-project.com/view/Xamarin.Android/job/xamarin-android-linux/lastSuccessfulBuild/Azure/ | grep -o "https://.*/Azure/processDownloadRequest/xamarin-android/oss-xamarin.android_v.*" > link.txt +RUN curl -L $(cat link.txt) \ + -o xamarin.tar.bz2 +RUN bzip2 -cd xamarin.tar.bz2 | tar -xvf - +RUN mv oss-xamarin.android_v* /android/xamarin && \ ln -s /android/xamarin/bin/Debug/lib/xbuild-frameworks/MonoAndroid/ /usr/lib/mono/xbuild-frameworks/MonoAndroid && \ - rm oss-xamarin.android_v7.3.99.59_Linux-x86_64_master_4799ea2.zip + rm xamarin.tar.bz2 ENV ANDROID_NDK_PATH=/android/sdk/ndk-bundle ENV ANDROID_SDK_PATH=/android/sdk/ From 773ed9f7efcc3e8054d2f1c795453ef9031cee10 Mon Sep 17 00:00:00 2001 From: Artyom Shalkhakov Date: Wed, 10 Jan 2018 13:57:20 +0600 Subject: [PATCH 2/3] Simplifying: use the xabuild command instead of msbuild. --- Dockerfile | 1 - 1 file changed, 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 750a34c..7811e83 100644 --- a/Dockerfile +++ b/Dockerfile @@ -24,7 +24,6 @@ RUN curl -L $(cat link.txt) \ -o xamarin.tar.bz2 RUN bzip2 -cd xamarin.tar.bz2 | tar -xvf - RUN mv oss-xamarin.android_v* /android/xamarin && \ - ln -s /android/xamarin/bin/Debug/lib/xbuild-frameworks/MonoAndroid/ /usr/lib/mono/xbuild-frameworks/MonoAndroid && \ rm xamarin.tar.bz2 ENV ANDROID_NDK_PATH=/android/sdk/ndk-bundle From 2faa6e6464af244d2c68a5b071e00fff2979b3a9 Mon Sep 17 00:00:00 2001 From: Artyom Shalkhakov Date: Wed, 10 Jan 2018 17:21:22 +0600 Subject: [PATCH 3/3] Bumping base Fedora version to 27 (latest). --- Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index 7811e83..2f848af 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM fedora:25 +FROM fedora:27 RUN dnf install gnupg wget dnf-plugins-core -y \ && rpm --import "http://keyserver.ubuntu.com/pks/lookup?op=get&search=0x3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF" \ @@ -19,7 +19,7 @@ RUN cd /android/sdk && \ ./tools/bin/sdkmanager 'build-tools;23.0.3' platform-tools 'platforms;android-23' 'ndk-bundle' RUN dnf install lynx -y -RUN lynx listonly -dump https://jenkins.mono-project.com/view/Xamarin.Android/job/xamarin-android-linux/lastSuccessfulBuild/Azure/ | grep -o "https://.*/Azure/processDownloadRequest/xamarin-android/oss-xamarin.android_v.*" > link.txt +RUN lynx -listonly -dump https://jenkins.mono-project.com/view/Xamarin.Android/job/xamarin-android-linux/lastSuccessfulBuild/Azure/ | grep -o "https://.*/Azure/processDownloadRequest/xamarin-android/oss-xamarin.android_v.*" > link.txt RUN curl -L $(cat link.txt) \ -o xamarin.tar.bz2 RUN bzip2 -cd xamarin.tar.bz2 | tar -xvf -