8000 GitHub - jewei/jerd: A native macOS app for local PHP development, databases, mail, and S3 storage. · GitHub
[go: up one dir, main page]

Skip to content
jeweiPublic

About

A native macOS app for local PHP development, databases, mail, and S3 storage.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Repository files navigation

Jerd

Jerd is a native macOS app for local PHP development. It does these tasks:

  • It serves your registered .test sites over HTTPS. Each site uses the PHP version that you select for it. A site can also have aliases, for example api.app.test, that serve the same document root.
  • It gives you php, composer, and laravel commands. These commands use the PHP version of the registered project that contains the current folder.
  • It manages MySQL, PostgreSQL, and Redis services, a Mailpit inbox for test mail, and RustFS storage with an S3 API.
  • It creates Cloudflare Tunnels with their DNS record for you, and runs connectors for tunnels that you already have.
  • It can set the route of a locally managed tunnel to a site, with verified HTTPS, or to a local address. The public hostname must already point to the tunnel in Cloudflare. Jerd warns you when a connected tunnel's hostname has no DNS record.
  • It checks for new runtime versions and installs them.

Requirements

  • A Mac with Apple silicon. Jerd does not run on an Intel Mac.

  • macOS 14 or later.

  • Ports 80 and 443 on 127.0.0.1 must be free. Other web servers must not use them.

  • An administrator account, to approve the HTTPS setup one time.

  • An internet connection the first time you add MySQL or PostgreSQL, and the first time you start Storage or Mail. The app includes Redis, but not MySQL, PostgreSQL, the Mailpit mail inbox, and the RustFS storage server. Jerd downloads one of them only when you select Install, Add Database, Start Storage, or Start Mail:

    Runtime Download Installed Free space during the install
    MySQL 8.4.11 168 MB 321 MB 489 MB
    PostgreSQL 18.6 122.5 MB 750.5 MB 873.1 MB
    Mailpit 1.31.3 9.8 MB 26.3 MB 36.2 MB
    RustFS 1.0.0 87 MB 223.5 MB 310.6 MB

    Jerd installs a runtime only when the download matches its reviewed checksum (and, for MySQL, the publisher signature). It checks the free space before the download. A runtime that an earlier copy of Jerd installed stays in use, and nothing is downloaded again.

Install and update

  1. Download the signed and notarized release from the GitHub releases page.
  2. Move Jerd.app to the Applications folder, then open it.
  3. To serve sites over HTTPS, open the Sites tab and approve the system setup.

Jerd uses Sparkle for app updates. It reads only the signed feed appcast.xml in this repository, over HTTPS. Sparkle installs an update only when its signature is correct. At the second launch, Jerd asks one time whether to check for updates automatically. It never installs an update without your approval. You can change the update settings on the About page of the Dashboard.

What Jerd changes on your Mac

Jerd changes system files only after you approve the change. These are the changes:

Change Purpose
A helper in Login Items & Extensions It opens ports 80 and 443 on 127.0.0.1 and makes the two changes below. It never starts a process
A section between # BEGIN JERD and # END JERD in /etc/hosts It sends your .test hostnames to 127.0.0.1
The certificate "Jerd Local CA" in the System keychain, with trust for TLS Browsers and PHP accept the HTTPS certificates of your sites
Optional: a PATH block in ~/.zprofile and ~/.zshrc It adds the php, composer, and laravel commands. Jerd keeps a backup of each file that it changes

To remove the changes, open the Sites tab, click the System Setup menu (the shield button in the toolbar), and select Remove System Setup…. Jerd stops the sites, removes its hosts section and its CA certificate, and removes its helper. Your site records and project files stay.

If Jerd cannot communicate with its helper, the Sites page shows a Reconnect Helper… button. The same command is in the System Setup menu. After an app update, Jerd restarts its helper by itself, one time. The helper also stops by itself after 30 seconds without work, so that macOS starts the current version on the next request.

Jerd keeps its data in ~/Library/Application Support/Jerd. The helper keeps its records in /Library/Application Support/JerdHelper. To remove all data, first remove the system setup. Then quit Jerd and delete these two folders. The second folder needs administrator approval. Also remove the tunnel tokens (service dev.jerd.cloudflared.tunnel-token) and the Cloudflare API token (service dev.jerd.cloudflare.api-token) in Keychain Access.

Privacy and safety

  • Jerd sends no analytics. It connects to the internet only to check for app and runtime updates, to download runtimes, and to run your tunnels.
  • All data services listen only on 127.0.0.1.
  • PHP, the web server, and the data services run as your user, not as root.
  • Jerd never deletes a project folder. Stop and Quit keep your databases, captured mail, buckets, objects, and credentials.
  • Jerd keeps tunnel tokens and the Cloudflare API token only in your Keychain.
  • Jerd changes Cloudflare only when you create or delete a tunnel. It never replaces a DNS record, and it never deletes a tunnel that it did not create.
  • When Jerd finds a damaged settings file, it keeps the file and tells you. It does not replace the file with empty settings.

Build from source

You need Xcode (the version in .xcode-version), XcodeGen, and swift-format. Do these steps in the repository folder:

  1. Run ./dev doctor. It checks the tools and gives install hints.
  2. Run ./dev runtimes prepare. It downloads, checks, and prepares the pinned runtimes.
  3. Run ./dev build. It builds an unsigned Debug app and shows its path.

Run ./dev help to see all commands. Read AGENTS.md before you change the code. More documents:

Document Contents
Architecture Modules, layers, the process model, and app startup
Data reference Every saved file, setting, and Keychain item
Run tests Unit tests, opt-in integration tests, and manual checks
Tools The ./dev tool, runtime payloads, and releases
Changelog Changes in each release

About

A native macOS app for local PHP development, databases, mail, and S3 storage.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Contributors

Languages

0