drupal / drupack
Installs drupack, which serves a Drupal project with its own PHP and web server, into the project root.
Requires
- php: >=8.1
- composer/semver: ^3
Requires (Dev)
None
Suggests
None
Provides
None
Conflicts
None
Replaces
None
- dev-main
- 1.0.0-beta11
- 1.0.0-beta10
- 1.0.0-beta9
- 1.0.0-beta8
- 1.0.0-beta7
- 1.0.0-beta6
- 1.0.0-beta5
- 1.0.0-beta4
- 1.0.0-beta3
- 1.0.0-beta2
- 1.0.0-beta1
- 1.0.0-alpha12
- 1.0.0-alpha11
- 1.0.0-alpha10
- 1.0.0-alpha9
- 1.0.0-alpha8
- 1.0.0-alpha7
- 1.0.0-alpha6
- 1.0.0-alpha5
- 1.0.0-alpha4
- 1.0.0-alpha3
- 1.0.0-alpha2
- 1.0.0-alpha1
- 0.9.0
- 0.8.1
- 0.8.0
- 0.7.1
- 0.7.0
- 0.6.1
- 0.6.0
- 0.5.5
- 0.5.4
- 0.5.3
- 0.5.2
- 0.5.1
- dev-sqlite-3-54
- dev-spc-v3-port
This package is auto-updated.
Last update: 2026-10-24 01:51:30 UTC
README
Drupack serves a Drupal project you already have from one executable. The executable carries PHP, FrankenPHP and Caddy. It uses the project's own settings, database and Drush.
This package installs the drupack executable into a Composer project.
Install
composer require --dev 'drupal/drupack:^1.0@alpha'
vendor/bin/drupack-install
./drupack
drupack-install downloads the drupack release matching the package's version into the project root, and checks its SHA-256. It adds /drupack to the project's .gitignore, and creates that file in a git project without one. On Windows the executable is drupack.exe.
Run vendor/bin/drupack-install again after composer update changes the package's version. A dev branch of the package names no release, so drupack-install refuses it.
Serve the project
./drupack serves the project in the working directory, or in the directory you name after it. It refuses a folder without Drupal core. It reads the docroot from the scaffold web root in composer.json, web by default.
The start prints a one-time login link through the project's Drush. It returns the prompt once the project answers on http://127.0.0.1:3787, and keeps serving in the background. A project without Drush serves with no link.
./drupack stopends it.--foregroundserves in the terminal instead.--listen IP:PORTpicks another address.--versionnames the release and the FrankenPHP, PHP, Caddy and SQLite it carries.
The project's own settings.php names the database, the files paths and the hash salt. Drupack writes nothing into the project. For a ddev project, point settings.local.php at the database's published port on 127.0.0.1.
Drush and PHP
./drupack drush COMMANDruns the project's own Drush on the bundled PHP, from any directory inside the project../drupack dr COMMANDruns Drupal core's command line the same way, on Drupal 11.4 and later../drupack php SCRIPT [ARGUMENTS]and./drupack php -r CODErun the bundled PHP.
A project whose composer.lock needs a PHP extension the bundled PHP lacks is refused. The message names the extension and the packages that need it.
Linux builds
A Linux release publishes a glibc build and a musl build per processor. drupack-install installs the glibc build when the host has the glibc loader at glibc 2.28 or later, and the musl build otherwise. DRUPACK_LIBC set to glibc or musl overrides that pick:
DRUPACK_LIBC=musl vendor/bin/drupack-install
The unpacked runtime
The first start of a version unpacks PHP and Caddy into a cache directory. Later starts of that version reuse it.
- Linux:
~/.cache/drupack/runtime - macOS:
~/Library/Caches/drupack/runtime - Windows:
%LOCALAPPDATA%\drupack\runtime
DRUPACK_CACHE_DIR moves the cache. DRUPACK_CA_FILE names a CA bundle for PHP's HTTPS requests, such as one holding a re-signing proxy's root certificate.
More
The Drupack repository covers installing without Composer, verifying a download and building an executable of your own site.