mirror of
https://github.com/HQarroum/docker-android.git
synced 2026-07-15 06:47:07 +02:00
Switch to ubuntu jre
This commit is contained in:
+12
-11
@@ -10,23 +10,24 @@ LABEL version "1.0.0"
|
|||||||
COPY deps/redir/redir.c /usr/src/redir.c
|
COPY deps/redir/redir.c /usr/src/redir.c
|
||||||
|
|
||||||
# Installing required packages.
|
# Installing required packages.
|
||||||
RUN apk update && \
|
RUN apt update --yes && \
|
||||||
apk upgrade && \
|
apt upgrade --yes && \
|
||||||
apk add --no-cache \
|
apt install --yes \
|
||||||
alpine-sdk \
|
build-essential \
|
||||||
bash \
|
bash \
|
||||||
unzip \
|
unzip \
|
||||||
wget \
|
wget \
|
||||||
libvirt-daemon \
|
libvirt-daemon-system \
|
||||||
dbus \
|
libvirt-clients \
|
||||||
polkit \
|
bridge-utils && \
|
||||||
virt-manager && \
|
|
||||||
# Compile `redir`.
|
# Compile `redir`.
|
||||||
gcc /usr/src/redir.c -o /usr/bin/redir && \
|
gcc /usr/src/redir.c -o /usr/bin/redir && \
|
||||||
strip /usr/bin/redir && \
|
strip /usr/bin/redir && \
|
||||||
# Cleanup APK.
|
# Cleanup APT.
|
||||||
apk del alpine-sdk && \
|
apt remove build-essential --yes && \
|
||||||
rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* /var/cache/apk/*
|
apt clean autoclean --yes && \
|
||||||
|
apt autoremove --yes && \
|
||||||
|
rm -rf /var/lib/{apt,dpkg,cache,log}/
|
||||||
|
|
||||||
# Arguments that can be overriden at build-time.
|
# Arguments that can be overriden at build-time.
|
||||||
ARG INSTALL_ANDROID_SDK=1
|
ARG INSTALL_ANDROID_SDK=1
|
||||||
|
|||||||
@@ -1,3 +1,7 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
# If the installation flag of the Android SDK is set
|
# If the installation flag of the Android SDK is set
|
||||||
# we download the Android command-line tools,
|
# we download the Android command-line tools,
|
||||||
# install the SDK, platform tools and the emulator.
|
# install the SDK, platform tools and the emulator.
|
||||||
|
|||||||
@@ -31,16 +31,11 @@ wait_for_boot &
|
|||||||
|
|
||||||
# Start the emulator with no audio, no GUI, and no snapshots.
|
# Start the emulator with no audio, no GUI, and no snapshots.
|
||||||
echo "Starting the emulator ..."
|
echo "Starting the emulator ..."
|
||||||
if emulator \
|
emulator \
|
||||||
-avd android \
|
-avd android \
|
||||||
-noaudio \
|
-noaudio \
|
||||||
-no-boot-anim \
|
-no-boot-anim \
|
||||||
-no-window \
|
-no-window \
|
||||||
-no-snapshot-save \
|
-no-snapshot-save \
|
||||||
-qemu \
|
-qemu \
|
||||||
-enable-kvm;
|
-enable-kvm || update_state "stopped"
|
||||||
then
|
|
||||||
update_state "stopped"
|
|
||||||
else
|
|
||||||
update_state "stopped"
|
|
||||||
fi
|
|
||||||
|
|||||||
Reference in New Issue
Block a user