Search by

CakePHP 2 application skeleton with a CakePHP 5-style directory layout

Package info

github.com/pieceofcake2/app

Type:project

pkg:composer/pieceofcake2/app

Statistics

Installs: 22 281

Dependents: 32

Suggesters: 0

Stars: 2

Open Issues: 0

v2.5.3 2026-10-19 05:10 UTC

README

GitHub License Packagist Version PHP CakePHP PHPStan

The application skeleton for CakePHP 2 applications running on pieceofcake2/cakephp, with a directory layout compatible with CakePHP 5 (config/, src/, templates/, tests/, webroot/), .env support, and the home page, layouts, error pages and styles of the CakePHP 5 skeleton.

Warning

CakePHP 2.x is for the maintenance of existing applications. For new projects, use the current major version of CakePHP instead.

Documentation

It covers the installation, the directory layout, the configuration and .env files, the pages and styles, running tests and PHPStan, and migrating an existing application to the modern layout.

For AI coding tools, the Markdown docs of the CakePHP 2 book are installed as a dev dependency (pieceofcake2/docs, files in vendor/pieceofcake2/docs/docs/en/).

Requirements

  • PHP 8.0+
  • Composer
  • MySQL 5.6+, PostgreSQL 9.4+, SQLite 3 or SQL Server 2022+

Installation

composer create-project pieceofcake2/app my_app

Then copy config/database.php.default to config/database.php, set the database with DATABASE_URL in config/.env.local (and the test database in config/.env.test.local) or the environment, and change the security salts in config/core.php (see Generating the Security Salts).

The Bake and DebugKit plugins are development dependencies. config/bootstrap.php loads them when they are installed, so bin/cake bake works out of the box and composer install --no-dev still works in production.

Contributing

See the contribution guidelines.

Origin

This package is based on the app/ directory of cakephp/cakephp (cakephp/cakephp on Packagist, last upstream version 2.10.24), originally by the CakePHP community (Cake Software Foundation, Inc.). It was extracted into a separate package and is maintained for CakePHP 2 on modern PHP by pieceofcake2. Changes from the original are listed in the commit history.

License

Licensed under the MIT License. See LICENSE.

webroot/css/normalize.min.css (normalize.css) and webroot/css/milligram.min.css (Milligram) are MIT licensed, see their headers. The Raleway font in webroot/font/ is licensed under the SIL Open Font License 1.1, see webroot/font/Raleway-License.txt.