peep.moe

Setup guide

Setting up PeepEn.

About half an hour on shared hosting. You need your hosting login, your mail server settings (IMAP and SMTP), and a license key.

Shared hosting

What you need

  • Hosting with PHP 8.1 or newer (8.4 included) and the pdo_sqlite, sodium, mbstring, iconv, openssl, dom and curl extensions. Most cPanel hosts have them; setup checks for you.
  • HTTPS on the address PeepEn will use (cPanel's free AutoSSL is fine).
  • Your mail server settings: IMAP and SMTP host names, ports and security. Your host's help pages list them.
  • Cron jobs (cPanel → Cron Jobs), so mail is checked when nobody has PeepEn open.

1. Get a license key

Make an account with your company name and confirm your email. The key appears on the page and in your inbox. Every install needs one, including the free plan.

Download the newest peepen-<version>.zip from your account.

2. Upload

In cPanel → File Manager, upload the zip into public_html and extract it into a folder, for example public_html/mail. Or use a subdomain like mail.yourcompany.com pointed at that folder.

3. Run setup

Open the address, for example https://yourcompany.com/mail/. Setup starts on its own:

  1. License key. It activates the key for this install and proves the install is yours.
  2. Checks. PHP and its extensions.
  3. Data folder. Setup suggests one next to public_html, never inside it. It holds the database and the key that encrypts mailbox passwords.
  4. The Owner. Name, username, a PIN of 6 to 12 digits (everyone signs in with a PIN), an authenticator app (scan the QR code; it's asked for only when you open the Admin center), and 10 recovery codes. Print or save them.
  5. Company and mail server. Entered once and tested with a real login; every mailbox you add later uses it.
peep.moe can't be reached from your hosting? Setup asks for the code in PEEPEN-SETUP-CODE.php, which it wrote into the folder. It still needs the key to activate before it finishes.

4. The cron job

Setup shows the exact line for your account. In cPanel → Cron Jobs, add it to run every minute:

* * * * * php /home/USER/public_html/mail/bin/peepctl.php tick

It checks every mailbox, runs rules and out-of-office replies, and sends reminders. New mail shows within a minute. Setup turns green when it sees the first run.

5. Add people

Admin center → People → Add person: name, username, groups, and their mailbox with its password (or let them type it at first sign-in). PeepEn shows a setup code (8 characters, good for 72 hours) and a printable welcome sheet. They open the address, choose First time here, or have a code from your admin?, and pick their PIN.

Then Admin center → Groups: make a group, give it shared mailboxes (read, send or manage) and a group calendar, and add people to it.

VPS

Console install

On a VPS with Apache, unzip into a folder Apache serves and either use the browser setup above, or the console (Rocky / RHEL shown; on Debian or Ubuntu use --user=www-data):

php /var/www/peepen/bin/peepctl.php check
php /var/www/peepen/bin/peepctl.php init --data=/var/lib/peepen --user=apache

With SELinux on, give the data folder a writable context:

semanage fcontext -a -t httpd_sys_rw_content_t "/var/lib/peepen(/.*)?" && restorecon -R /var/lib/peepen
sudo -u apache php /var/www/peepen/bin/peepctl.php owner boss --name="Your Name" [email protected]

owner prints a setup code: open the site, choose First time here, or have a code from your admin?, pick a PIN and set up the authenticator, then enter the license key under Admin → License. AllowOverride All must be on for the folder so its .htaccess files protect lib/, bin/ and config.php.

Push service

On a VPS, run the push service instead of cron: it holds one connection per mailbox, so new mail shows within seconds (tested at 280 mailboxes in about 42 MB).

dnf install -y php-process
sudo tee /etc/systemd/system/peepen.service >/dev/null <<'EOF'
[Unit]
Description=PeepEn push service (peepd)
After=network-online.target

[Service]
User=apache
WorkingDirectory=/var/www/peepen
ExecStart=/usr/bin/php bin/peepd.php
Restart=always
RestartSec=5

[Install]
WantedBy=multi-user.target
EOF
sudo systemctl daemon-reload && sudo systemctl enable --now peepen && systemctl status peepen --no-pager

Docker

PeepEn also comes as a Docker image: ghcr.io/peep-moe/peepen, PHP 8.4 with Apache, built from the same signed release. One container runs PeepEn and its push service, and everything it keeps is in the /data volume. Save this as compose.yml:

services:
  peepen:
    image: ghcr.io/peep-moe/peepen:latest
    container_name: peepen
    restart: unless-stopped
    ports:
      - "127.0.0.1:8080:8080"
    volumes:
      - peepen-data:/data
    environment:
      TZ: America/New_York

volumes:
  peepen-data:
docker compose up -d && docker logs peepen

The log shows the setup code. PeepEn listens on 127.0.0.1:8080 only, so point your HTTPS reverse proxy at it (sending X-Forwarded-Proto: https), open your address and run setup in the browser. To update, run docker compose pull && docker compose up -d; Admin → About & updates tells you when there's a new version. The console works through docker exec peepen php bin/peepctl.php.

Afterwards

Phones

Peep for iPhone and iPad and Peep for Android link to PeepEn the same way the computers do (below): scan the QR code on the person's welcome sheet, or type the address, username and setup code. They get mail, calendars, chat and Drive.

To use the phone's own calendar and contacts apps instead, each person adds their phone under Settings → Phones → Add, which gives that phone its own password. On iPhone or iPad, scan the QR code with the camera within 15 minutes and install the profile. On Android, use DAVx⁵ with the server address, username and password shown. The phone gets their calendar, shared calendars, rooms and the company directory.

The Peep apps

Install Peep for Windows, Mac or Linux from the download page (Mac also from the Mac App Store), then link it to your PeepEn address with a username and setup code. The mailboxes, calendars, chat and Drive come from the server, so there's nothing to set up on the computer.

Moving from Peep Web

Someone already using Peep Web for themselves can bring their contacts, calendar, tasks, notes, rules and settings: in Peep Web, Settings → Server → Export my data; then in PeepEn, Settings → Import. Importing again later only adds what's new or changed.

Updating

Admin → About & updates → Check for updates, then Update now. PeepEn installs a release only when its signature (made with a key kept offline), size and checksum check out, and keeps the old files so Go back can restore them. Where PHP can't change PeepEn's own files (a VPS unpacked as root), the page shows the command to run instead:

cd /var/www/peepen && php bin/peepctl.php update

By hand still works: upload the new zip over the old folder and extract it, replacing files. config.php and the data are never in the zip. The database updates itself on the next visit and the push service restarts itself. In Docker: docker compose pull && docker compose up -d.

Moving to a new server

Copy the data folder to the new server and install PeepEn there. In your account, choose Move to a new server on the key, then enter it under Admin → License on the new install.

Locked out

WhoWhat to do
StaffAn admin unlocks them or makes a new setup code (Admin → People).
An adminThe Owner does the same for admins.
The Owner, with recovery codesUse one: it works like a setup code.
The Owner, without themCreate an empty file named RESET-OWNER in PeepEn's folder (File Manager or FTP) and open the sign-in page. It becomes RESET-OWNER-CODE.php with a one-time code, which proves you control the server.

Still stuck? Write to info@peep.moe.