Skip to main content

Inferyx CodeGate

Browser VS Code (code-server) for many users on one Ubuntu server. Each user gets their own Docker workspace; admins manage everything from a web portal.

  • Login: username/password, and optionally AWS IAM Identity Center (SSO).
  • One container per user, with CPU/RAM/disk limits and its own home folder.
  • Admin portal for users, approvals, resources, sessions, audit log and settings.
https://code.example.com/codeapp/                    → sign in
https://code.example.com/codeapp/editor/<username>/  → that user's VS Code
https://code.example.com/codeapp/admin/              → admin portal

Requirements

  • Ubuntu 24.04 server with root (sudo) access
  • Python 3.10+ (sudo apt install -y python3-pip python3-venv)
  • A DNS name pointing to the server, ports 80 and 443 open
  • Optional: AWS IAM Identity Center, if you want SSO login

Install

# 1. install into its own virtual environment
sudo python3 -m venv /opt/inferyx-codegate
sudo /opt/inferyx-codegate/bin/pip install "inferyx-codegate[saml]"
sudo ln -sf /opt/inferyx-codegate/bin/inferyx-codegate /usr/local/bin/inferyx-codegate

# 2. set everything up (asks for the domain and the default admin's email + password)
sudo inferyx-codegate setup

# 3. check
sudo inferyx-codegate doctor

If installing [saml] fails to build xmlsec, install inferyx-codegate without [saml]; inferyx-codegate setup then installs the system libraries and the SAML library for you.

Unattended install:

sudo inferyx-codegate setup -y --domain code.example.com --admin-email admin@example.com \
  --admin-password-file /root/admin-pw.txt   # omit to generate a password (shown once)

What setup does

Setup is safe to run again: it checks each part and skips what's already in place.

Part What happens
Packages Installs only what's missing: nginx, docker.io, quota, certbot, xmlsec libraries
Docker Reuses an existing Docker install; builds the workspace image (code-server, Python, AWS CLI)
Default admin Creates the first admin with password login. Must change a generated password at first login
nginx Writes only its own files (/etc/nginx/inferyx-codegate/, /etc/nginx/conf.d/inferyx-codegate-map.conf). Never edits your existing nginx files (see below)
HTTPS Runs certbot only for a site Inferyx CodeGate created itself (--skip-ssl to skip)
Host SSH Adds /etc/ssh/sshd_config.d/10-inferyx-codegate.conf so workspace users can't SSH into the server
Service systemd service inferyx-codegate plus a daily backup timer
Existing code-server Detected; you choose keep, stop or disable

nginx: one manual line

If your domain already has an nginx server { } block, add this line inside it (the 443 block), then reload nginx. Setup and inferyx-codegate doctor show the exact file:

include /etc/nginx/inferyx-codegate/inferyx-codegate.conf;
sudo nginx -t && sudo systemctl reload nginx

If the domain has no server block, setup creates its own site and you don't need this step.

First sign-in

  1. Open https://<your-domain>/codeapp/ and sign in as the default admin.
  2. Change the password when asked.
  3. Users → Add user: enter the email, set a temporary password (or Generate), choose a plan. The user's Linux account, home folder, container and route are created automatically.
  4. Give the user their temporary password over a secure channel. They must change it at first sign-in, then VS Code opens.

AWS SSO login (optional)

  1. AWS console → IAM Identity Center → Applications → Add application → I have an application I want to set up → SAML 2.0.

  2. In Inferyx CodeGate: Settings → Login. Copy the ACS URL and SAML audience shown there into the AWS application ("Manually type your metadata values").

  3. AWS Attribute mappings:

    User attribute in the application Maps to Format
    Subject ${user:email} emailAddress
    email ${user:email} unspecified
    name (optional) ${user:name} unspecified
  4. Copy the IAM Identity Center SAML metadata file URL from AWS into SAML metadata URL, click Test metadata, switch on AWS SSO login, and Save.

  5. In AWS, assign users or groups to the application. New SSO users wait as pending until an admin approves them, unless their email domain is on the auto-approve list.

Password login and SSO can each be switched off in Settings → Login; at least one stays on.

Login security

  • Passwords are stored only as salted scrypt hashes. Rules: at least 12 characters, 3 of lowercase / uppercase / digit / symbol, not containing the username or email.
  • After 5 failed attempts an account is locked for 15 minutes (adjustable); admins can unlock it from the user page. Attempts are also rate-limited per IP address.
  • Sessions use a random token in an HttpOnly, Secure cookie; only its hash is stored. A new token is issued at every sign-in and password change. Session length and idle timeout are in Settings.
  • Changing or resetting a password ends the user's other sessions. Turning a login method off ends the sessions that used it.
  • Sign-in, sign-out and password forms are protected against cross-site requests.

Locked out of the web portal?

On the server:

sudo inferyx-codegate user passwd <admin-username-or-email>   # set a new password (--generate for random)
sudo inferyx-codegate user unlock <user>
sudo inferyx-codegate auth show
sudo inferyx-codegate auth enable password

Day-to-day commands

sudo inferyx-codegate status | start | stop | restart | logs -f
sudo inferyx-codegate doctor                                 # checks everything, prints fix hints
sudo inferyx-codegate user add dev@example.com --plan medium --password
sudo inferyx-codegate user set <user> --plan large           # CPU/RAM apply live
sudo inferyx-codegate user delete <user> --remove-home       # home is archived first
sudo inferyx-codegate admin add second-admin@example.com
sudo inferyx-codegate backup | restore <file>

Full list: inferyx-codegate --help, and inferyx-codegate <command> --help.

Upgrade

sudo inferyx-codegate upgrade --dry-run    # show the plan
sudo inferyx-codegate upgrade              # latest version from PyPI

Before upgrading, it backs up the database, config and nginx files, plus the installed package. After installing, it runs migrations, refreshes nginx routes and restarts the service. If any step fails, the previous version is restored automatically.

Disk limits

Without Linux disk quotas, limits are monitored every 5 minutes and a workspace over its limit is stopped. For hard limits, enable quotas on the /home filesystem (maintenance window):

sudo apt install -y quota linux-image-extra-virtual
# add usrquota to the /home (or /) line in /etc/fstab, then:
sudo mount -o remount /
sudo quotacheck -cum /
sudo quotaon -v /
sudo inferyx-codegate doctor               # "Disk quotas on /home" should show ✓

Files

Path Contents
/etc/inferyx-codegate/inferyx-codegate.env configuration (inferyx-codegate config show)
/var/lib/inferyx-codegate/inferyx-codegate.db database: users, sessions, audit log, settings
/var/lib/inferyx-codegate/backups/ daily and pre-upgrade backups
/var/log/inferyx-codegate/inferyx-codegate.log service log
/etc/nginx/inferyx-codegate/ generated nginx config
/home/<user> user files (mounted into their container)

Good to know

  • Admins can't open other users' VS Code.
  • Workspace users can't sign in to the server over SSH; they only get VS Code.
  • sudo inside a workspace makes the user root in their container. Only give it to people you would trust with the server. Mounting /home with nosuid adds protection (inferyx-codegate doctor checks it).
  • The service runs as root (it manages Linux users, Docker and nginx) but listens only on 127.0.0.1; nginx is the only public entry point.
  • Signing out of Inferyx CodeGate doesn't sign the user out of the AWS access portal.

Metadata

Release files for inferyx-codegate 2.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for inferyx-codegate 2.0.1
File Size Uploaded Provenance Actions
inferyx_codegate-2.0.1.tar.gz 663.8 kB Without provenance Details for inferyx_codegate-2.0.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for inferyx-codegate 2.0.1
File Interpreter ABI Platform Actions
inferyx_codegate-2.0.1-py3-none-any.whl Python 3 none any Details for inferyx_codegate-2.0.1-py3-none-any.whl

Total release size: 1.4 MB

Release files / inferyx_codegate-2.0.1.tar.gz

Download URL inferyx_codegate-2.0.1.tar.gz
Size 663.8 kB
Tags Source
SHA-256 checksum
How to use checksums
2166f262d8a7905f6ab915178b51db7d3219ee06295be7727a374d4c2e1d8674
BLAKE2b-256 checksum
How to use checksums
aabd48f233d764732855f85be2efaf6464eb0217da7802949874761129ea9db3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.15.2

Release files / inferyx_codegate-2.0.1-py3-none-any.whl

Download URL inferyx_codegate-2.0.1-py3-none-any.whl
Size 694.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
039c4805913bb7ed73534a202a378385bf9767436434316a624bac2f04d69bb8
BLAKE2b-256 checksum
How to use checksums
9451496ac87a0c8694937462ad2ae0271dc9dbc4b657430ac863f3f621539e19
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.15.2

Security for inferyx-codegate 2.0.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page