Ubuntu – Ubuntu Touch (UBports) and Android support for LXC/LXD containers (for running Ubuntu): current state

androidlxcubuntu-touch

I am trying to run a web-server on my Android device (several available models, ARM or x86 hardware) inside a container (lxc / lxd). Looking for the easiest and safest way to do it. I was thinking about installing ubuntu-server on a smartphone. The task has led me in the direction of unlocking the bootloader, replacing the recovery and flashing a custom ROM (which needs to be found / chosen / tested / trusted OR developed). Before diving into xda-developers forum and Android SDK docs I am trying to figure out whether it is possible to make lxc / lxd run directly on Android (which version).

The only (very old) post by St├ęphane Graber on the subject – section "LXC on Android devices" – has left me rather pessimistic. According to him LXC support on Android devices hasn't been a priority, although it was generally possible…

I've also come across mentioning of lxc-android-config tool: here and here. However it lacks documentation or any kind of user-oriented notes.

Related questions:

1)How to install ubuntu server for lxc on a smartphone (ARM or x86)?

2)How to use Android SDK and smartphone vendor tools to boot another kernel?