Skip to content

Self-hosting

Requirements

What you need before you install: Node.js 22 LTS (20.9 or later works) for source installs, Docker with Compose v2 and about ${DOCKER_BUILD_MEMORY_GB} GB of memory for building the image, Kubernetes 1.27+ and Helm 3, PostgreSQL 15+, and the ports and app address UserTasks uses.

Last updated 5 min read Edit this page on GitHub
On this page

What you need depends on how you run it. Nothing in UserTasks needs outbound internet at runtime; it only calls out to services you configure (integrations, an email provider, an AI provider).

Software#

You're runningYou need
One-line installerLinux or macOS with Docker Engine and the Compose plugin (2.20 or later), or Docker Desktop; Windows 10/11 with Docker Desktop on WSL 2. curl or wget. No Node.js or git. About 2 GB of memory for the containers (4 GB or more recommended) and 5 GB of disk
Laptop trialDocker (Docker Desktop, or Docker Engine with the Compose plugin), git, and Node.js 22 LTS (20.9 or later works) to run the npm run stack helper. About 2 GB of memory for Docker when it uses the published image; about 10 GB when it has to build the image itself (below)
From source (npm run dev, npm start)Node.js 22 LTS, which the Docker image also uses, and npm. Node.js 20.9 or later still works (npm prints an EBADENGINE warning for one package, and Node.js 20 is past its end of life). Plus a database: a Supabase project, a local Supabase (Docker and the Supabase CLI, npx supabase), or PostgreSQL 15+
Docker ComposeDocker Engine with Compose v2.20 or later (the docker compose command)
KubernetesKubernetes 1.27 or later and Helm 3
Air-gapped bundleOn the offline host: a shell, sha256sum, OpenSSL 3 and Docker with the Compose plugin. No Node.js. For Kubernetes, also helm and a container registry the cluster can pull from
The CLINode.js 20 or later (22 LTS recommended) on the machine where you run usertasks

Database: PostgreSQL 15 or later with the pg_trgm extension. Supabase includes it.

Memory for the Docker build#

The laptop trial (npm run stack -- up) and docker compose up use the published image for this version (ghcr.io/homepresso/usertasks) when one is available: it's a download, nothing is compiled, and this section doesn't apply. When there's no published image to pull (none has been published for this version yet, or there's no network), they build the image locally instead. npm run stack -- up --build, docker compose up --build and docker build always build locally.

Building compiles UserTasks inside Docker. That needs about 10 GB of memory for Docker, and the first build takes 10 to 20 minutes. Below that, the build stops with Killed or cannot allocate memory.

  • Docker Desktop (macOS, Windows): Settings → Resources → Memory → 10 GB or more → Apply & restart. On Windows with WSL 2, the limit is memory= in %UserProfile%\.wslconfig.
  • Other containers running at the same time (a local Supabase, for example) use some of that memory too.
  • npm run stack -- up checks Docker's memory before it builds (never before a download) and stops with these steps when there isn't enough (--skip-memory-check builds anyway).
  • Running the finished stack needs far less, about 2 GB.
  • On a laptop with little memory, run from source instead (npm run setup:local): nothing is compiled inside Docker.

Memory for running it#

A running stack (the published image: app, worker, PostgreSQL, MinIO, Valkey, Mailpit) is capped at about 4.1 GB for Docker with 6 GB or more, and about 2.8 GB on a smaller host: docker-compose.yml limits each container and each Node process, so a heavy workflow slows down instead of starving the computer. The installers pick the small-host values when Docker has under 6 GB; the values and how to change them are in Deployment profiles → Running memory.

  • Windows PC with 8 GB (Docker Desktop on WSL 2): set %UserProfile%\.wslconfig to [wsl2], memory=5GB, swap=2GB, run wsl --shutdown, then start Docker Desktop again. Docker gets ~4.8 GB and Windows keeps the rest. Without it, WSL 2 can take half the PC's memory and keep it.
  • 16 GB or more: memory=8GB (or Docker Desktop's default) and the standard values.
  • Heavy workflows run inside the web app: WORKFLOW_CONCURRENCY (5; 2 on a small host) is how many run at once.

Ports#

PortWhat uses itChange it with
3000The app: web pages, the API and /docsPORT for npm run dev / npm start, APP_PORT for Docker Compose, service.port in the Helm chart (default 80 inside the cluster)
8025Mailpit, the test inbox in the laptop trial and the standalone profile (on 127.0.0.1 only)MAILPIT_PORT
9001MinIO console in the laptop trial and the standalone profile (on 127.0.0.1 only)MINIO_CONSOLE_PORT
54321–54324A local Supabase started with npx supabase start (API, database, Studio, mail)supabase/config.toml
a random port on 127.0.0.1The CLI's browser login, on the machine running the CLInothing to open: it's local

In the standalone profile, PostgreSQL, MinIO's API and Valkey stay inside the Docker network: they aren't published on the host.

The app's address#

APP_URL (or NEXT_PUBLIC_APP_URL; APP_URL wins when both are set) is the address people type in, for example https://tasks.example.com or http://localhost:3000. Get it exactly right:

  • Include the scheme and the port if there is one, and leave off the trailing slash.
  • It's used for links in emails and for sign-in and SSO redirects.
  • An https:// address makes the sign-in cookies Secure, so browsers only send them over HTTPS. An http:// address doesn't.
  • Some pages are built ahead of time, so set it when you build (for Docker, it's a build argument) as well as when you run. After changing it, rebuild.

In production, serve the app over HTTPS behind a reverse proxy (nginx, Caddy, Traefik, a cloud load balancer or a Kubernetes ingress). The proxy must pass the original Host header through. Give your install a friendly address walks through DNS, HTTPS and APP_URL step by step. The file upload limits list the body size each proxy needs.

Use HTTP/2 at the proxy. Each open UserTasks page keeps one live-update connection to the server. Over HTTP/1.1, browsers allow only six connections per address, so someone with several UserTasks tabs (or SharePoint pages showing UserTasks forms) open can find saves and page loads queuing behind them. Hidden tabs give their connection back after 30 seconds, but HTTP/2 removes the limit altogether. Caddy, Traefik, IIS and cloud load balancers use HTTP/2 over HTTPS by default; in nginx add http2 to the listen 443 ssl line.

Windows servers: antivirus#

On a Windows host that runs UserTasks without Docker (Node.js and PostgreSQL installed on Windows), Microsoft Defender's real-time protection scans every file UserTasks and PostgreSQL write, and every file they read for the first time. That includes the app's server code after each upgrade or restart, PostgreSQL's data and WAL files, and the logs. On our test server, reading 1,500 newly written app files took 5 to 14 seconds with scanning, and under 1 second with an exclusion. Defender was also the busiest process on the machine.

Exclude the UserTasks folders from real-time scanning, in PowerShell run as administrator. Adjust the paths to your install:

PowerShell
Add-MpPreference -ExclusionPath 'C:\UserTasks\app', 'C:\UserTasks\data', 'C:\UserTasks\pgsql'
Get-MpPreference | Select-Object -ExpandProperty ExclusionPath

For other antivirus products, exclude the same folders. The PostgreSQL project also advises keeping antivirus away from the data directory: besides the slowdown, a scanner holding a file open can make PostgreSQL fail to rename or delete it.

The trade-off: Defender no longer scans files in those folders, on access or in scheduled scans, so malware placed there wouldn't be caught. Keep the exclusions narrow:

  • Exclude the folders, not node.exe or postgres.exe as processes. A process exclusion skips every file the process touches, anywhere on the disk.
  • Don't keep uploads you haven't scanned in an excluded folder. If you store files on the local disk, keep that folder outside the exclusion, or scan uploads another way.
  • Make sure only the service account and administrators can write to the excluded folders.
  • Scan new releases before you install them, since they land in an excluded folder.

Next#

Install step by step.

Was this page helpful?