Deploy private-python-registry
Private Python package registry with devpi, pip/uv compatibility.
private-python-registry
Just deployed
/data
Deploy and Host private-python-registry on Railway
private-python-registry is a ready-to-deploy Railway template that launches your own private Python package index, powered by devpi. It is fully compatible with standard Python tooling — pip, uv, twine, and devpi-client — and ships with a built-in web UI, search, and an on-demand PyPI mirror that caches public dependencies into your own persistent storage.
About Hosting private-python-registry
Hosting private-python-registry on Railway is a one-click affair. The template builds a single container running devpi-server + devpi-web, exposes it on Railway's managed HTTPS domain, and persists every package, user, and login token to a Railway Volume mounted at /data. A persistent server secret is generated on first boot so authentication tokens survive redeploys, and initial admin credentials are seeded from a single DEVPI_ROOT_PASSWORD environment variable. No external database, no reverse proxy, no moving parts — just a Dockerfile, a volume, and a generated domain. Redeploys and restarts are fully idempotent.
Common Use Cases
- Publish and share proprietary Python packages across an engineering team without exposing them on public PyPI
- Host an internal PyPI mirror that caches public dependencies, giving your CI reproducible, fast, and outage-resilient installs
- Distribute pre-release, staging, or customer-specific package builds through isolated per-user indexes with fine-grained access control
Dependencies for private-python-registry Hosting
- A Railway Volume mounted at
/data— stores all packages, indexes, users, logins, and the persistent server secret. Without it, every redeploy wipes the registry. - A public Railway domain generated from the service's Networking settings — required for
pip,uv,twine, anddevpi-clientto reach the index over HTTPS.
Deployment Dependencies
- devpi documentation — upstream project powering the registry
- devpi-server on PyPI
- devpi-web on PyPI — web UI and search
- devpi-client on PyPI — CLI used to create users, indexes, and upload packages
- Railway Volumes documentation
- Railway Public Networking documentation
Implementation Details
After deployment, set DEVPI_ROOT_PASSWORD before the first boot, attach a Volume at /data, and generate a public domain. Then, from any machine with devpi-client installed:
# Point the client at your new registry and log in as root
devpi use https://
devpi login root --password="$DEVPI_ROOT_PASSWORD"
# Create a user and a private index that falls through to PyPI
devpi user -c alice password=s3cret [email protected]
devpi index -c alice/prod bases=root/pypi
# Publish a package with twine
twine upload \
--repository-url https:///alice/prod/ \
--username alice --password s3cret \
dist/*
# Install it back with pip or uv
pip install --index-url https://alice:s3cret@/alice/prod/+simple/ my-private-pkg
uv pip install --index https://alice:s3cret@/alice/prod/+simple/ my-private-pkg
By default the template runs devpi-server with --restrict-modify root, so only the root user can create additional users and indexes. Set DEVPI_RESTRICT_MODIFY="" if you want any authenticated user to create their own indexes instead.
Why Deploy private-python-registry on Railway?
Railway is a singular platform to deploy your infrastructure stack. Railway will host your infrastructure so you don't have to deal with configuration, while allowing you to vertically and horizontally scale it.
By deploying private-python-registry on Railway, you are one step closer to supporting a complete full-stack application with minimal burden. Host your servers, databases, AI agents, and more on Railway.
Template Content
private-python-registry
hallcyn/private-python-registry