Running JupyterHub for Canadian clients: data residency

I’m setting up JupyterHub for a few Canadian clients, and some of them need personal and research data kept in Canada because of PIPEDA, plus stricter public-sector rules in BC and Quebec. Here’s the checklist I’m working from. I’d like to hear what others would add.

  1. Run the hub and single-user servers on infrastructure physically located in Canada, and confirm the region in writing.
  2. Keep user home directories and persistent volumes in the same Canadian region, including any shared data mounts.
  3. Back up home directories and the hub database only to Canadian storage, encrypted, with a clear retention period.
  4. Check where the authenticator sends logins. An external OAuth provider may process user data outside Canada.
  5. Pin container images and review which extensions or kernels call outside services.
  6. Set resource limits, idle culling and admin roles so access stays narrow.
  7. Write down where notebooks, outputs, logs and backups live, so clients can answer audit questions quickly.

For those running JupyterHub with residency requirements: how do you handle authentication and storage so nothing leaves the country?

How strict do you want/need to be? It’s impossible to 100% guarantee that data can’t leave your country, you always need to have a level of trust in your users.

For example, you could include geo-ip restrictions in your authenticator or front-end proxy, but users could use a VPN to get around that. You could block known VPN IP ranges, but that won’t catch residential IP VPNs.

In the UK we use Trusted Research Environments to provide access to sensitive data. These typically prevent outbound network access from a singleuser server, and also require access to be via a VDI such as Apache Guacamole so that you can’t download data from JupyterLab, and you can also disable the clipboard.

However that still won’t prevent someone from taking a screenshot or photo, and a modern AI agent will happily operate a browser inside a VDI just by analysing the canvas.