spam-n-eggs/laravel-mysqlite
A Laravel package that adds a MySQLite database driver, combining SQLite's lightweight footprint with MySQL-style compatibility for local development and testing. Install via Composer and configure it through Laravel's standard database connections.
Package: dominion-solutions/laravel-mysqlite — a Laravel service provider that adapts MySQL-specific SQL semantics onto SQLite (column types, grammar/blueprint extensions, and function shims) so that applications can run their MySQL-targeted test or local environment against SQLite.
Architecture fit. The integration surface is narrow and favorable: a single Laravel service provider that decorates the connection/grammar layer. This is a drop-in for the default sqlite driver in config/database.php rather than a replacement for the ORM, so it composes with Eloquent, the query builder, and migrations without touching application code. For teams maintaining a MySQL-in-production / SQLite-in-CI split, this package targets a real and recurring pain point (JSON column queries, FULLTEXT indexes, enum, ON DUPLICATE KEY, GROUP_CONCAT, date functions). Architectural risk rises only where the package reaches into grammar internals, which Laravel has historically treated as semi-private API.
Integration feasibility. v2.0.2 is a CI-only change — it adds Laravel 11 to the test matrix (PR #128). No runtime code, no public API, no schema or config changes. The actionable signal is compatibility attestation: the maintainer now continuously verifies against Laravel 11. This matters because Laravel 11 removed the HTTP/Console kernels from the default skeleton and shifted framework internals; a provider that hooks the connection layer is generally shielded, but the added matrix row is the first evidence of Laravel 11 support. Feasibility for a trial is high: one composer require --dev, one connection config entry, one test-suite run.
Technical risk.
FULLTEXT emulation) and the PHP pdo_sqlite version. Divergence here produces silent wrong-result failures, not loud errors — the worst failure class for a test harness.ORDER BY on mixed types, integer/float affinity, NULL ordering, and strict-mode errors. Tests passing on SQLite can mask MySQL production failures, and vice versa.Key questions.
doctrine/dbal still required, given Laravel 11's movement away from it for column modification?Stack fit. Best suited to teams on Laravel 10 or 11 whose production datastore is MySQL 8 and whose CI or local environment is SQLite. Fit degrades for teams already running MySQL containers in CI (no need), for teams on Postgres (out of scope), and for teams using MySQL-only features heavily (risk concentration). The package is dev-only; it should never appear in require.
Migration path. Low-friction, reversible, and best run as a bounded experiment:
composer require --dev dominion-solutions/laravel-mysqlite.mysqlite) in config/database.php alongside the existing sqlite entry rather than overwriting it, so rollback is a config revert.phpunit.xml's DB_CONNECTION at the new connection in one CI job only, leaving existing jobs untouched.--pretend checks; diff failures against the SQLite baseline to isolate what the package fixes versus breaks.Compatibility. v2.0.2 adds Laravel 11 to the verified matrix; Laravel 10 is presumably already covered by prior rows — confirm in the repo's workflow file rather than inferring from the changelog. Pin to ^2.0 and let Composer resolve. Note that PHP version constraints follow the Laravel major (8.2+ for Laravel 11), which may force a CI image upgrade independent of this package.
Sequencing. (1) Verify the CI matrix contents and SQLite/PHP versions. (2) Add the dev dependency and a parallel connection in a throwaway branch. (3) Run the suite; classify failures as package gap, genuine MySQL-dependency, or emulation false-negative. (4) If pass rate is high, promote to one required CI job and keep the MySQL job as the authoritative gate. (5) Only after sustained green, consider using it for local developer environments. Do not sequence this ahead of any active Laravel 11 upgrade — land the upgrade first, then evaluate.
Maintenance. Minimal runtime footprint: one dev dependency, one config block, no migrations, no production artifacts, no infrastructure. The real maintenance cost is the emulation contract — as the application adopts new MySQL features, someone must verify the package still covers them. Assign that to whoever owns test infrastructure, and add a line to the upgrade checklist for Laravel majors.
Support. Upstream is a small, single-maintainer OSS project; there is no commercial support and no SLA. Budget for the possibility of abandonment: because the integration is config-isolated, the exit cost is a config revert plus removal of the dependency. Internal knowledge should not be concentrated in one engineer.
Scaling. Irrelevant in the horizontal sense — this does not run in production. It does scale test throughput: SQLite suites run materially faster and with less orchestration than containerized MySQL, which is the primary justification. The scaling limit is suite diversity: a single SQLite job cannot replace MySQL integration coverage for MySQL-specific behavior.
Failure modes.
require-dev only, plus a CI lint on composer.json.Ramp-up. Near zero for setup — under an hour for a competent Laravel engineer to wire the connection and get a signal. The expensive part is interpretation, not installation: engineers must understand why a test that passes here may still fail in production. Document that expectation explicitly, and frame the package as a fast-feedback complement to MySQL integration testing, not a substitute for it.
Assessment of v2.0.2. Routine CI hygiene with real but modest signal value — it is the first affirmative evidence of Laravel 11 compatibility, and it carries no breaking changes, deprecations, or new features. Recommend a low-risk, time-boxed trial in a single CI job; do not treat this release as sufficient grounds for expanding the package's role beyond dev/test.
How can I help you explore Laravel packages today?