drago-ex / project-install
Application installation package.
Package info
github.com/drago-ex/project-install
Type:drago-tools-resource
pkg:composer/drago-ex/project-install
Requires
- php: >=8.3 <9
- drago-ex/application: ^4.0
- drago-ex/bootstrap: ^2.0
- drago-ex/component: ^3.0
- drago-ex/database: ^4.0
- drago-ex/form: ^3.0
- drago-ex/migration: ^1.0
- drago-ex/project-auth: ^1.0
- drago-ex/project-backend: ^1.0
- drago-ex/project-backend-ui: ^1.0
- drago-ex/project-docker: ^1.0
- drago-ex/project-docker-db: ^1.0
- drago-ex/project-front: ^1.0
- drago-ex/project-settings: ^1.0
- drago-ex/translator: ^4.0
Requires (Dev)
- drago-ex/project-tools: ^1.0
- nette/tester: ^2.5
- phpstan/phpstan-nette: ^2.0
Suggests
None
Provides
None
Conflicts
None
Replaces
None
This package is auto-updated.
Last update: 2026-10-29 16:31:50 UTC
README
Application installation package.
Requirements
- PHP >= 8.3, < 9
- Drago Project
Installation
composer require drago-ex/project-install
Files copied into the project
The files are copied into the project by drago-ex/project-tools,
as set in extra.drago-tools of this package's composer.json.
How it works
Until the application is installed, www/index.php runs only the installer (app/Presentation/Install).
The wizard tests the database connection, writes app/db.neon, runs the migrations, sets up the website
and creates the administrator account. The steps go in order and cannot be skipped.
Installation lock
Finishing the wizard writes app/installed.lock; while it exists, the application runs instead of the installer.
Keep it on the server, and commit it or add it to .gitignore depending on how you deploy.
Migrations
The installer runs the migrations of all installed packages in their migration-priority order, then the project's
own migrations/, the same way as vendor/bin/migration db:migrate --packages. Executed files are recorded,
so the installer can be run again after a failure, and later migrations run from the console:
php vendor/bin/migration db:migrate --packages
Console
app/app.neon registers drago-ex/migration and contributte/console, so commands such as
vendor/bin/migration work. Inside Docker, run them as the web user, so files in temp/ keep the
right owner:
docker compose exec -u www-data server php vendor/bin/migration list
Extending the installer
Another package can add its own steps by a service in app/Presentation/Install/ (the installer loads its neon
files and classes):
- tag
install.migrations: a callable object that gets the project root and returns more migrations; they run after the package migrations and before the project's own, - tag
install.account: a callable object that gets the id of the new administrator.
services: - {factory: App\Presentation\Install\AccountSetup, tags: [install.account], autowired: no}