Skip to the content.

How to install PICR

Using Docker

Picr is built to be run as a docker container on your NAS / Server.

There are other ways you could install it, but docker is recommended and the only officially supported method.

If you have never used docker before then just google _“install docker on "_ (EG: windows 10 / mac os 15 / synology)

Once installed, we will use the following docker compose file. This is basically a “recipe” for PICR and a postgres database.

Compose file

Create an empty folder on your server (perhaps called picr) and put the following compose.yml file in there.

services:
  picr:
    container_name: 'picr'
    image: 'isaacinsoll/picr'
    volumes:
      - <path-to-your-shared-images>:/home/node/app/media:ro # read only access to your 'files i give to clients' folder
      - ./cache:/home/node/app/cache #where PICR will store thumbnails it generates, no need to back it up
    depends_on:
      - db
    ports:
      - "6900:6900" # presumably reverse proxy will handle HTTPS
    environment:
      - BASE_URL=https://clients.mydomain.com/ #change this to your URL
      - DATABASE_URL=postgres://user:pass@db/picr
      - USE_POLLING=true # recommended if you have > 10,000 files
  db:
    image: postgres:17
    container_name: picr-db
    environment:
      POSTGRES_USER: user
      POSTGRES_PASSWORD: pass
      POSTGRES_DB: picr
    volumes:
      - ./data:/var/lib/postgresql/data #database storage, you should back this up

Volumes (File Locations)

Folder Description Backup
data database (you should back this up!)
Technically it’s used by db not picr
Yes
media mount point containing folders of images, PICR only needs read access.
Often this would be a folder that already exists unless you are starting from scratch
Yes
cache thumbnails, zip files built from your media
It’s safe to delete contents of this folder, will be recreated if deleted
(not required)

If you have a folder you are already using then point the media mount to that, otherwise you can make a new folder whereever you want.

Typically media and cache will be created in the folder you are putting the compose file in for simplicity.

Environment variables

There are lots of environment variables you can use, but only a few are needed:

Run PICR

Start the docker compose stack and it should start PICR and the postgres database. You should see output in docker saying ‘you need a token secret, heres one…’, add that to your compose.yml and then start the container again.

Once it’s up and running you can then log in. Go to the url (EG: http://:6900/) and login with the default login of `admin` / `picr1234`

Change the account details (username and password), then start using PICR 🔥