Code Anywhere: A 5‑Minute Smartphone Remote‑Coding Guide

Code Anywhere: A 5‑Minute Smartphone Remote‑Coding Guide

In a world where developers move between coffee shops, co‑working spaces, and airports, the ability to code from a smartphone has become essential. The "Doom Coding" project shows you how to set up a 24/7 laptop, a lightweight smartphone terminal, and an AI‑powered coding assistant so you can write, debug, and ship code anywhere.

TL;DR – 1) Keep a laptop on 24/7 2) Install Tailscale and enable SSH 3) On your phone install Tailscale + Termius 4) Point Termius at your laptop’s MagicDNS 5) Open a terminal and run claude.

What You’ll Need

Item Why it Matters
Laptop/desktop Must stay powered on / unlocked, connected to the Internet at all times.
Ubuntu/Mac/Windows The guide covers Ubuntu/Windo’s SSH setup; Mac users can follow the same patterns.
Tailscale Creates a private VPN over the public Internet; MagicDNS eliminates IP‑address fiddling.
Termius (iOS / Android) A free mobile SSH client that supports bookmarks, aliases, and SSH key auth.
Claude‑Pro subscription Provides a CLI claude command that auto‑generates code, docs, and answers on the fly.
Optional: PostgreSQL client Lets you query databases directly from your phone if you run services on the laptop.

Step 1 – Power up the Laptop

  1. Disable Sleep – In Settings → Power → Sleep, set the timeout to Never or a very long time.
  2. Enable Remote Login
  3. Mac: System Settings → General → Remote Login → On.
  4. Ubuntu: sudo systemctl enable ssh then sudo systemctl start ssh.
  5. Windows: Open PowerShell as administrator and run:
    Enable-WindowsOptionalFeature -Online -FeatureName OpenSSH.Server~~~~0.0.1.0
    Start-Service sshd
    Set-Service -Name sshd -StartupType Automatic
    
  6. Verify SSH – From another PC, run ssh username@<IP> and make sure you can connect.

Tip – If you plan to run a Jupyter or a local web server, you’ll also need to open the relevant ports in your firewall.

Step 2 – Install Tailscale on the Laptop

  1. Download the Tailscale package for your OS from the official site.
  2. Install and login with the same Google/Apple/SSO account you plan to use on your phone.
  3. In Tailscale’s admin console (via https://login.tailscale.com/admin/machines), navigate to Access Controls.
  4. Disable IPv4 for all devices – this forces Termius to use MagicDNS, which is the most reliable way to reach your laptop.
  5. Screenshot example: The Access Controls page should show IPv4 disabled under All Machines.
  6. Note down your MagicDNS address – it looks like my‑computer.tailnet‑name.ts.net.

Step 3 – Set Up Your Phone

  1. Install Tailscale – available on the App Store / Google Play.
  2. Install Termius – the modern SSH client.
  3. Add a new host in Termius:
  4. Label – e.g., "Doom‑Laptop"
  5. Hostname – your laptop’s MagicDNS address.
  6. Port22.
  7. Login – your laptop username.
  8. Key/Password – you can use a password for the first run, then swap for an SSH key.
  9. Open the Tailscale app and make sure the VPN is toggled On.

Step 4 – Connect and Code

  1. In Termius, tap your newly added host.
  2. Once connected, you will see a shell prompt. From here launch the Claude CLI:
    claude my
    
  3. You can now:
  4. Write code snippets.
  5. Ask for code explanations.
  6. Generate unit tests.
  7. Run local scripts.
  8. If you want to preview a local web app, set up a simple HTTP server:
    python -m http.server 3005
    
    and visit http://my‑computer.tailnet‑name.ts.net:3005/ on your phone’s browser.
  9. To interact with a local database, use the PostgreSQL client from the App Store, and connect to remote=<MagicDNS>, dbname=….

Troubleshooting Common Issues

Symptom Likely Cause Fix
Termius shows Disconnected Tailscale VPN off Toggle Tailscale ON or re‑sync the VPN.
SSH authentication fails IPv4 still enabled Disable IPv4 in Tailscale admin.
Laptop disconnects after 10 min Laptop locked/hung when monitor attached Disconnect the monitor or change power settings.
claude command not found Path missing Add ~/.profile entry: export PATH=$PATH:/path/to/claude and reload.

Best Practices & Extended Use

  • Keep the laptop unlocked – The SSH daemon will stop if the laptop locks in some configs.
  • Use SSH keys – More secure and avoids password prompts.
  • Leverage CLAUDE.md – Have Claude automatically append session notes or code chunks to a markdown file.
  • Preview local assets – Use your phone’s browser to view static sites or APIs; replace localhost with your MagicDNS.
  • Bookmark common sites – Store Google OAuth, GitHub, docs on your laptop, so you can quickly access them from the phone’s Chrome app.

Wrap‑Up

With just a few minutes of setup, the Doom Coding workflow transforms an ordinary laptop into a mobile‑centric coding hub. You can write, debug, run tests, and view web apps—all from the palm of your hand. The combination of Tailscale’s secure mesh, Termius’s lightweight terminal, and Claude’s AI‑assisted command line makes remote development painless and productive.

Happy doom coding! If you discover new tweaks or encounter bugs, contribute to the GitHub repo or drop a note at [email protected]. Your feedback keeps the ecosystem thriving."}

Original Article: View Original

Share this article