A web-based control panel to create and manage locally hosted domains on your Android device using Termux. Turn your phone into a powerful, pocket-sized server for development and private projects.
(The Dot-Tux control panel running in a mobile browser.)
Dot-Tux leverages the power of Nginx and Python Flask running within Termux to host multiple websites on a single Android device. The primary domain, dot.tux, serves a user-friendly web interface that allows you to dynamically add and remove other local domains (like flipper.tux or my-project.tux) without ever touching the command line again.
This creates a perfect, zero-cost, sandboxed environment for web development, testing, or hosting private applications accessible only on your local network.
- Zero-Cost Hosting: Run a real web server directly on your Android device.
- Dynamic Domain Management: A simple web UI (
dot.tux) to add/remove Nginx sites on the fly. - Automated Setup: A single
install.shscript handles all dependencies and configuration. - Boots on Start: Integrates with Termux:Boot to launch the server automatically when your device starts.
- Lightweight & Portable: Built on a minimal stack, requiring very few resources.
- Safe Reloads: Includes configuration checks to prevent broken Nginx configs from being loaded.
- Termux Server: An Nginx instance runs on your device, listening for requests on port
8080. A Python Flask app runs onlocalhost:5000to serve the control panel. - Nginx Virtual Hosts: The
nginx.conffile is configured with multipleserverblocks. Nginx directs traffic fordot.tuxto the Flask app, and traffic for all other.tuxdomains to their corresponding static file directories. - Dot-Tux Control Panel: The Flask app provides a web interface that can read, write, and safely modify the
nginx.conffile. When you add a domain, the app creates a new directory, generates a newserverblock, and triggers a script to safely reload Nginx. - Local DNS Resolution: To access these sites, other devices on the same Wi-Fi network must have their
hostsfile edited to point the.tuxdomains to the IP address of the Termux device.
Follow these steps to get Dot-Tux up and running.
- Termux installed on your Android device.
- Termux:Boot installed from F-Droid for auto-start functionality.
- Your Android device and client computer must be on the same Wi-Fi network.
- Battery optimization must be disabled for both Termux and Termux:Boot apps in your phone's settings.
# Update packages and install git
pkg update && pkg upgrade -y
pkg install git -y
# Clone the repository
git clone https://github.com/SullyGreene/Dot-Tux.git
# Navigate into the project directory
cd Dot-Tux
# Make the installer executable
chmod +x install.sh
# Run the installer script. This will set up everything.
./install.shThe installer will guide you through the process and give you the IP address of your device at the end.
To access your .tux domains, you need to tell your computer where to find them.
-
Find your Termux device's local IP address. If you missed it during installation, run
ifconfigin Termux and look for theinetaddress under thewlan0interface (e.g.,192.168.1.42). -
Edit your
hostsfile with administrator/sudo privileges.- Windows:
C:\Windows\System32\drivers\etc\hosts - macOS / Linux:
/etc/hosts
- Windows:
-
Add an entry for the control panel. Replace
YOUR_TERMUX_IPwith the IP you just found.
# Dot-Tux Server
YOUR_TERMUX_IP dot.tux
You will need to add new lines here for every domain you create later (e.g., YOUR_TERMUX_IP flipper.tux).
Open a web browser on your computer and navigate to:
http://dot.tux:8080
You should now see the Dot-Tux control panel, ready to manage your domains!
Inside the Dot-Tux directory in Termux, you can use these scripts to control the server manually:
./start.sh: Starts the Nginx and Python services../stop.sh: Stops all related services and releases the wakelock../reload.sh: Safely tests and reloads the Nginx configuration (used internally by the app).
Contributions are welcome! If you have an idea for a new feature or have found a bug, please open an issue or submit a pull request.
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature) - Commit your Changes (
git commit -m 'Add some AmazingFeature') - Push to the Branch (
git push origin feature/AmazingFeature) - Open a Pull Request
This project is distributed under the MIT License. See LICENSE.txt for more information.