Run from Docker
We have gained support for running our images from Docker thanks to @sickcodes and his Dock-Droid project. Our stable Android 9 based images are default, but you can load up a specific image as well (helpful for testing in a development environment)

Exerpt below taken from: https://github.com/sickcodes/dock-droid

Initial setup

Before you do anything else, you will need to turn on hardware virtualization in your BIOS. Precisely how will depend on your particular machine (and BIOS), but it should be straightforward.
Then, you'll need QEMU and some other dependencies on your host:
1
# ARCH
2
sudo pacman -S qemu libvirt dnsmasq virt-manager bridge-utils flex bison iptables-nft edk2-ovmf
3
4
# UBUNTU DEBIAN
5
sudo apt install qemu qemu-kvm libvirt-clients libvirt-daemon-system bridge-utils virt-manager
6
7
# CENTOS RHEL FEDORA
8
sudo yum install libvirt qemu-kvm
Copied!
Then, enable libvirt and load the KVM kernel module:
1
sudo systemctl enable --now libvirtd
2
sudo systemctl enable --now virtlogd
3
4
echo 1 | sudo tee /sys/module/kvm/parameters/ignore_msrs
5
6
sudo modprobe kvm
Copied!

Quick Start

Run Bliss OS 11.x Image

1
docker run -it \
2
--device /dev/kvm \
3
-v /tmp/.X11-unix:/tmp/.X11-unix \
4
-e "DISPLAY=${DISPLAY:-:0.0}" \
5
-p 5555:5555 \
6
sickcodes/dock-droid:latest
Copied!
Increase RAM by adding this line: -e RAM=4 \
Want to use your WebCam and Audio too?
v4l2-ctl --list-devices
lsusb to get the hostbus and hostaddr
1
Bus 003 Device 003: ID 13d3:56a2 IMC Networks USB2.0 HD UVC WebCam
Copied!
Would be -device usb-host,hostbus=3,hostaddr=3
1
docker run -it \
2
--privileged \
3
--device /dev/kvm \
4
-v /tmp/.X11-unix:/tmp/.X11-unix \
5
-e "DISPLAY=${DISPLAY:-:0.0}" \
6
-p 5555:5555 \
7
-p 50922:10022 \
8
--device /dev/video0 \
9
-e EXTRA='-device usb-host,hostbus=3,hostaddr=3' \
10
--device /dev/snd \
11
sickcodes/dock-droid:latest
Copied!
Want to use SwiftShader acceleration?
1
docker run -it \
2
--privileged \
3
--device /dev/kvm \
4
-v /tmp/.X11-unix:/tmp/.X11-unix \
5
-e "DISPLAY=${DISPLAY:-:0.0}" \
6
-p 5555:5555 \
7
-p 50922:10022 \
8
--device=/dev/dri \
9
--group-add video \
10
-e EXTRA='-display sdl,gl=on' \
11
sickcodes/dock-droid:latest
Copied!
In development by BlissOS team: mesa graphics card + OpenGL3.2.

Use your own image/naked version

1
# get container name from
2
docker ps -a
3
4
# copy out the image
5
docker cp container_name:/home/arch/dock-droid/android.qcow2 .
Copied!
Use any generic ISO or use your own Android AOSP raw image or qcow2
Where, "${PWD}/disk.qcow2" is your image in the host system.
1
docker run -it \
2
-v "${PWD}/android.qcow2:/home/arch/dock-droid/android.qcow2" \
3
--privileged \
4
--device /dev/kvm \
5
--device /dev/video0 \
6
-v /tmp/.X11-unix:/tmp/.X11-unix \
7
-e "DISPLAY=${DISPLAY:-:0.0}" \
8
-p 5555:5555 \
9
-p 50922:10022 \
10
-e EXTRA='-device usb-host,hostbus=3,hostaddr=3' \
11
sickcodes/dock-droid:latest
Copied!

Custom Build

1
CDROM_IMAGE_URL='https://sourceforge.net/projects/blissos-x86/files/Official/bleeding_edge/Generic%20builds%20-%20Pie/11.13/Bliss-v11.13--OFFICIAL-20201113-1525_x86_64_k-k4.19.122-ax86-ga-rmi_m-20.1.0-llvm90_dgc-t3_gms_intelhd.iso'
2
3
docker build \
4
-t dock-droid-custom \
5
-e CDROM_IMAGE_URL="${CDROM_IMAGE_URL}" .
Copied!

How to connect using ADB

In the Android terminal emulator:
Edit /default.prop
Change ro.adb.secure=1 to ro.adb.secure=0
E.g.
1
su
2
sed -i -e 's/ro\.adb\.secure\=1/ro\.adb\.secure\=0/' /default.prop
Copied!
In the Android terminal emulator, run adbd
Then from the host, you can can connect using either: adb connect localhost:5555
adb connect 172.17.0.2:5555
For further information, and even information. on a dockerized build environment for Bliss OS, please visit: https://github.com/sickcodes/dock-droid
Last modified 4mo ago