Installation
Before you start
Pocket ID requires a secure context, meaning it must be served over HTTPS. This is necessary because Pocket ID uses the WebAuthn API.
You can use a reverse proxy like Caddy or NGINX to serve Pocket ID over HTTPS. Alternatively, you can use a service like Cloudflare to provide HTTPS for your domain.
Installation Methods
Installation with Docker (recommended)
-
Download the
docker-compose.yml
and.env
file:curl -O https://raw.githubusercontent.com/pocket-id/pocket-id/main/docker-compose.yml
curl -o .env https://raw.githubusercontent.com/pocket-id/pocket-id/main/.env.example -
Edit the
.env
file so that it fits your needs. See the environment variables section for more information. -
Run
docker compose up -d
You can now sign in with the admin account on https://<your-app-url>/login/setup
.
Stand-alone Installation
-
Download the latest binary from the releases page.
Make sure to download the correct version for your operating system. The binary names follow this pattern:
pocket-id-<operating-system>-<architecture>
- Example:
pocket-id-linux-amd64
You can use curl to download the binary directly. For example, for Linux on AMD64 architecture:
curl -L -o pocket-id-linux-amd64 https://github.com/pocket-id/pocket-id/releases/latest/download/pocket-id-linux-amd64
-
Rename the binary and make it executable:
mv pocket-id-<operating-system>-<architecture> pocket-id
chmod +x pocket-id -
Download the
.env
file:curl -o .env https://raw.githubusercontent.com/pocket-id/pocket-id/main/.env.example
-
Edit the
.env
file so that it fits your needs. See the environment variables section for more information. -
Run the binary:
./pocket-id
You can now sign in with the admin account on https://<your-app-url>/login/setup
.
Community Installation Methods
These installation methods are not officially supported, and services may not work as expected.
Proxmox
Run the helper script as root in your Proxmox shell.
Configuration Paths
- /opt/pocket-id/backend/.env
- /opt/pocket-id/frontend/.env
bash -c "$(wget -qLO - https://github.com/community-scripts/ProxmoxVE/raw/main/ct/pocketid.sh)"
Unraid
Pocket ID is available as a template on the Community Apps store.
Kubernetes Helm Chart
- A Helm chart maintained by @hobit44 is available here.
- A Helm chart maintained by anza-labs:
NixOS
A pocket-id module is available in NixOS Unstable.
It can be enabled by adding the following to your configuration.nix
:
services.pocket-id.enable = true;
For further configuration of the module, see the available settings.
Installation from Source
It's not recommended to install Pocket ID from source unless you know what you're doing. The following instructions are provided for advanced users who want to customize or contribute to the project.
Required tools:
-
Run the following commands:
# Clone the repo
git clone https://github.com/pocket-id/pocket-id
cd pocket-id
# Checkout latest version
git fetch --tags && git checkout $(git describe --tags `git rev-list --tags --max-count=1`)
# Build the frontend
cd frontend
npm ci
npm run build
# Build the backend
cd ../backend/cmd
go build -o ../../pocket-id
# Create the .env file
cd ../../
cp .env.example .env -
Edit the
.env
file so that it fits your needs. See the environment variables section for more information. -
Run the binary:
./pocket-id
You can now sign in with the admin account on https://<your-app-url>/login/setup
.