Skip to content

Repository files navigation

Python-NoAdmin

Bootstrap Python without administrator, root, or sudo access.

A cross-platform solution for developers working in restricted environments who need a fully functional Python runtime without elevated privileges.

PythonPlatformLicenseNo Admin

Quick Start

Windows

install.cmd

macOS / Linux

chmod +x install.sh
./install.sh

That's it! The installer will:

  1. Download a bootstrap Python (first run only)
  2. Install your chosen Python version to ~/.python-nonadmin
  3. Install pip
  4. Configure your PATH

Advanced Usage

# Install specific version
./install.sh --version 3.11.9
# Force reinstall
./install.sh --force
# List available versions
./install.sh --list
# Uninstall
./install.sh --uninstall

Windows (PowerShell)

# All the same flags work
.\install.cmd--version 3.11.9
.\install.cmd--list
.\install.cmd--uninstall

Features

  • No admin/sudo required – Installs entirely in user-writable directories
  • Cross-platform – Works on Windows, macOS (Intel & Apple Silicon), and Linux (x86_64 & ARM64)
  • Version selection – Install any supported Python version
  • Complete Python – Includes pip and full standard library
  • Virtual environment support – Create isolated environments as usual
  • Self-contained – Uses bundled bootstrap Python, no dependencies

How It Works

┌─────────────────────────────────────────────────────────────┐
│ install.cmd / install.sh │
│ ↓ │
│ Downloads bootstrap Python to bin/python/ (first run) │
│ ↓ │
│ Runs install.py with bootstrap Python │
│ ↓ │
│ install.py downloads target Python version │
│ ↓ │
│ Installs to ~/.python-nonadmin │
│ ↓ │
│ Configures pip + PATH │
└─────────────────────────────────────────────────────────────┘

Platform-Specific Approaches

PlatformBootstrap PythonTarget Python
WindowsPython embeddable packagePython embeddable package
macOSpython-build-standalonepython-build-standalone
Linuxpython-build-standalonepython-build-standalone

Installation Directory

PlatformLocation
Windows%USERPROFILE%\.python-nonadmin
macOS$HOME/.python-nonadmin
Linux$HOME/.python-nonadmin

Verifying Installation

python --version
pip --version
python -c "import sys; print(sys.executable)"
python examples/demo.py

Activating in Current Session

After installation, either restart your terminal or:

Windows (PowerShell)

. .\scripts\activate.ps1

macOS / Linux

source ./scripts/activate.sh

Creating Virtual Environments

python -m venv myproject-env
# Activate# Windows: .\myproject-env\Scripts\Activate.ps1# Unix: source myproject-env/bin/activate
pip install requests flask pandas

Troubleshooting

Windows

Execution policy error:

Set-ExecutionPolicy-Scope CurrentUser -ExecutionPolicy RemoteSigned

Corporate proxy:

$env:HTTP_PROXY="http://proxy.company.com:8080"$env:HTTPS_PROXY="http://proxy.company.com:8080"
.\install.cmd

macOS

Gatekeeper warning:

xattr -dr com.apple.quarantine ~/.python-nonadmin

Linux

glibc version mismatch:

  • Default builds require glibc 2.17+
  • For very old systems, consider building from source

Platform-Specific Documentation


Use Cases

  • 🏢 Corporate laptops – Work on locked-down enterprise machines
  • 🎓 Academic labs – Develop on shared university computers
  • 🔒 Sandboxed environments – CI/CD pipelines with limited permissions
  • 💾 Portable development – Run Python from USB drives
  • 🧪 Testing – Isolated Python versions for testing

Configuration

Edit config.json to change default Python version and download URLs.

Supported versions (tested):

  • 3.12.8 (default)
  • 3.12.7
  • 3.11.9
  • 3.11.8
  • 3.10.14
  • 3.10.13

Uninstallation

./install.sh --uninstall
# or on Windows:
install.cmd --uninstall

This removes the ~/.python-nonadmin directory. You may also want to clean up shell profile entries manually.


License

MIT License - See LICENSE for details.


Contributing

Contributions welcome!

About

🐍 Bootstrap Python without admin/sudo access. Cross-platform installer for Windows, macOS & Linux. Perfect for locked-down corporate machines, academic labs, and CI/CD pipelines. No elevated privileges required.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages