Skip to content

Dev Environment ‐ Set up on Phone

Full Stack edited this page Mar 23, 2025 · 10 revisions

Installation steps

  • Update termux: apt-get update && apt-get upgrade -y
  • Install wget: apt-get install wget -y
  • Install proot: apt-get install proot -y
  • Install git: apt-get install git -y
  • Go to HOME folder: cd ~
  • Download script: git clone https://github.com/MFDGaming/ubuntu-in-termux.git
  • Go to script folder: cd ubuntu-in-termux
  • Give execution permission: chmod +x ubuntu.sh
  • Run the script: ./ubuntu.sh -y
  • Now just start ubuntu: ./startubuntu.sh

To Check Ubuntu Version

lsb_release -a

Termux

How to install Termux X11 native DESKTOP on ANDROID (no proot) - [No Root] - Linux on Android

Setup docker-qemu-arm

git clone https://github.com/antonyz89/docker-qemu-arm
cd docker-qemu-arm
./termux-setup.sh

Refer: https://github.com/AntonyZ89/docker-qemu-arm

How to run docker on android

read

Install the docker-qemu-arm

Login into alphine by navigating to folder alphine

cd alphine
./startqemu.sh

user: root password: Secret123

Port forwarding

Important: Run time layer: Android -> Termux -> Alphine -> Docker Daemon Instance -> Containers

So, port forwarding is mandatory to expose the container port from alphine to termux - in order to access the endpoints.

How to forward a port from Termux native to Alpine to be able to access the apps:

From the docker-qemu-arm/alpine folder:

ssh -i qemukey -L 8080:localhost:4647 root@localhost -p 2222

This will forward the port 8080 in Termux native to the port 4647 in the Alpine container.

How to package nginx app and dockerize and run it

References

Clone this wiki locally