konradmichalik/php-sync-tool

Synchronize databases and files between local and remote systems over SSH/rsync/SFTP with framework credential auto-detection (TYPO3, Symfony, Drupal, WordPress, Laravel). PHP port of db-sync-tool.

Maintainers

Package info

github.com/konradmichalik/php-sync-tool

pkg:composer/konradmichalik/php-sync-tool

Transparency log

Statistics

Installs: 1

Dependents: 0

Suggesters: 0

Stars: 0

Open Issues: 0

v0.1.0 2026-08-27 12:30 UTC

This package is auto-updated.

Last update: 2026-08-27 12:34:22 UTC


README

Tests Packagist Version License

PHP port of db-sync-tool — synchronize databases (and optionally files) between local and remote systems over SSH/rsync/SFTP, with framework credential auto-detection for TYPO3, Symfony, Drupal, WordPress and Laravel.

📖 Read the documentation

✨ Features

  • Synchronize databases between local and remote systems
  • MySQL, MariaDB and PostgreSQL
  • Declarative data anonymization for GDPR-safe copies
  • Named environments with init, pull and push
  • Guards against overwriting the wrong database: confirmation prompt, protected hosts, and an optional backup of the target before the import
  • Optional file synchronization over SSH/rsync/SFTP
  • Framework credential auto-detection for TYPO3, Symfony, Drupal, WordPress and Laravel

🔥 Installation

composer require konradmichalik/php-sync-tool

Or use the standalone PHAR build (sync-tool.phar), see Installation.

Important

Needs PHP 8.2+, the client for your database system on the executing host(s) (mysql/mysqldump, or psql/pg_dump for PostgreSQL), gzip/gunzip, and rsync (optionally sshpass for password-based rsync).

🚀 Quick start

bin/sync-tool init            # writes .sync-tool/ for this project
bin/sync-tool pull production # that environment's database into this project

Called with no arguments on a terminal, the tool offers every sync it finds and runs the one you pick. See the CLI Reference for explicit configuration files, named hosts and the full option list.

🧑‍💻 Contributing

Please have a look at CONTRIBUTING.md.

⭐ License

This project is licensed under the GPL-3.0-or-later license.