{"id":14677372,"url":"https://github.com/bastien70/dbsaver","last_synced_at":"2025-09-09T03:31:22.816Z","repository":{"id":37025955,"uuid":"397582696","full_name":"bastien70/dbsaver","owner":"bastien70","description":"A Symfony application for managing and automating regular backups of MySQL databases.","archived":false,"fork":false,"pushed_at":"2023-12-30T22:13:21.000Z","size":1896,"stargazers_count":43,"open_issues_count":3,"forks_count":5,"subscribers_count":3,"default_branch":"main","last_synced_at":"2024-09-13T12:00:11.239Z","etag":null,"topics":["hacktoberfest","php","symfony"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/bastien70.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-08-18T11:53:15.000Z","updated_at":"2024-09-08T13:05:43.000Z","dependencies_parsed_at":"2023-01-28T23:15:14.902Z","dependency_job_id":null,"html_url":"https://github.com/bastien70/dbsaver","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"purl":"pkg:github/bastien70/dbsaver","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bastien70%2Fdbsaver","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bastien70%2Fdbsaver/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bastien70%2Fdbsaver/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bastien70%2Fdbsaver/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bastien70","download_url":"https://codeload.github.com/bastien70/dbsaver/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bastien70%2Fdbsaver/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":274238703,"owners_count":25247110,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-09-09T02:00:10.223Z","response_time":80,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["hacktoberfest","php","symfony"],"created_at":"2024-09-12T09:01:19.250Z","updated_at":"2025-09-09T03:31:22.461Z","avatar_url":"https://github.com/bastien70.png","language":"PHP","funding_links":[],"categories":["PHP"],"sub_categories":[],"readme":"# DbSaver\n\n[![Package version](https://img.shields.io/github/v/release/bastien70/dbsaver.svg?style=flat-square)](https://github.com/bastien70/dbsaver/releases)\n[![Build Status](https://img.shields.io/github/workflow/status/bastien70/dbsaver/Continuous%20Integration/main?style=flat-square)](https://github.com/bastien70/dbsaver/actions?query=workflow%3A\"Continuous+Integration\"+branch%3Amain)\n[![License](https://img.shields.io/badge/license-MIT-red.svg?style=flat-square)](LICENSE)\n[![Code coverage](https://img.shields.io/codecov/c/github/bastien70/dbsaver?style=flat-square)](https://codecov.io/gh/bastien70/dbsaver/branch/main)\n\n![Database list](docs/images/database-list.png?raw=true)\n\nDbSaver is an application written by **Bastien LOUGHIN** allowing you to make automatic daily backups (and manual backups) for your MySQL databases.\nAll you have to do is fill the credentials to access the databases, configure a CRON job... and it's done.\nPasswords will be automatically hashed.\n\nThen, using DbSaver, you can access your databases backups by browsing the **Backups** tab.\n\nYou can then use DbSaver to access databases backups by going to the **Backups** tab.\nBackups can be saved **locally** or in **S3 cloud** (AWS, Scaleway, ...).\n\n/!\\ DbSaver only backups databases. Files (like image uploads) are not saved.\n\n# Table of contents\n\n1. [Prerequisites](#prerequisites)\n1. [Manual install](#manual-install)\n1. [Install using Task](#task-install)\n1. [Configure the CRON job](#cron)\n1. [Use the application](#use-app)\n    1. [Login](#login)\n    1. [Manage storage spaces](#storage-spaces)\n    1. [Manage databases](#databases)\n    1. [Manage backups](#backups)\n1. [Update the application](#update-app)\n1. [License](#license)\n1. [Contribute](#contribute)\n1. [Changelog](#changelog)\n\n\n## Prerequisites \u003ca name=\"prerequisites\"\u003e\u003c/a\u003e\n\n* PHP 8.1+\n* Composer\n* Symfony CLI (if you want to run the project locally)\n\n## Manual install \u003ca name=\"manual-install\"\u003e\u003c/a\u003e\n\n1. `git clone https://github.com/bastien70/dbsaver.git`\n1. `cd dbsaver`\n1. `composer install --optimize-autoloader` (install dependencies)\n1. `php bin/console app:post-install` (project configuration)\n1. `php bin/console app:regenerate-app-secret` (regenerate the secret key allowing to hash databases passwords)\n1. `php bin/console d:d:c` (create database)\n1. `php bin/console d:m:m -n` (migrate tables)\n1. `php bin/console app:make-user` (create your account)\n\n## Install using Task \u003ca name=\"task-install\"\u003e\u003c/a\u003e\n\nRequires [Symfony CLI](https://symfony.com/download) and [Task](https://taskfile.dev/) to be installed.\n\n1. `git clone https://github.com/bastien70/dbsaver.git`\n1. `cd dbsaver`\n1. `task install`\n1. If you want to run Docker containers (currently only for local emails with MailCatcher): `task docker-start` et `task docker-stop` (requires Docker and Docker Compose)\n1. To start the server: `task start` (to stop it: `task stop`)\n\n## Configure the CRON job \u003ca name=\"cron\"\u003e\u003c/a\u003e\n\nConfigure the CRON task allows you to activate the verification of backups to be made. **Set it up to run every day**.\n\nWhen you add databases, you can each time configure the periodicity of the backups to be made.\nThe CRON task will automatically fetch the databases that need to be backed up and perform the automatic backup.\n\nHere is the command to run: `php bin/console app:backup`\n\nInitialize a CRON job on your server or computer:\n\n`[path to php] [path to project root]/bin/console app:backup`\n\n## Use the application \u003ca name=\"use-app\"\u003e\u003c/a\u003e\n\nAfter deploying the application on your server (or launching it locally) access the login page.\nFor the example the host will be `127.0.0.1:8000`.\n\n### Login \u003ca name=\"login\"\u003e\u003c/a\u003e\n\nAccess the app: https://127.0.0.1:8000/login\n\nYou'll be asked to log in. Enter your account credentials (that you created using the `php bin/console app:make-user` command).\n\n![Authentication](docs/images/login.png?raw=true)\n\nYou will be redirected to https://127.0.0.1:8000/\n\n![Homepage](docs/images/home.png?raw=true)\n\n### Manage storage spaces \u003ca name=\"storage-spaces\"\u003e\u003c/a\u003e\n\nTo create a storage space (locally or using S3), click on the `Storage spaces` tab then on the one you want. Then click on `Add storage space`.\nFill in the information for your storage space and validate.\n\n![Add storage space](docs/images/adapter-create.png?raw=true)\n\nYou will find this storage space in the list.\n\n![Storage space list](docs/images/adapter-list.png?raw=true)\n\n### Manage databases \u003ca name=\"databases\"\u003e\u003c/a\u003e\n\nTo create a database, click the `Databases` tab, then the `Add a database` button.\nFill your database information.\n\nThen, check the **backup options** \nto your needs.\n\nFinally, configure the **periodicity** at which a backup must be executed for your database (example: every day, every 2 weeks, every 3 months, ...)\n\n![Add a database](docs/images/database-create.png?raw=true)\n\nThen, for every database you add, you will be able to see its backups, update its credentials, delete the database from the app (and its backups) or launch a manual backup.\n\n![Database list](docs/images/database-list.png?raw=true)\n\n\n### Manage backups \u003ca name=\"backups\"\u003e\u003c/a\u003e\n\nTo access your databases backups, click the `Backups` tab.\n\n![Backup list](docs/images/backup-list.png?raw=true)\n\nYou will be able to download, restore or delete a backup.\n\n## Update the application \u003ca name=\"update-app\"\u003e\u003c/a\u003e\n\nIf you have Task and Symfony CLI installed, just run this command: `task update`\n\nElse run the following commands instead:\n\n```bash\ngit pull --rebase\ncomposer install --optimize-autoloader\nphp bin/console doctrine:migrations:migrate --no-interaction\nphp bin/console app:post-install --only-missing\n```\n\n## License \u003ca name=\"license\"\u003e\u003c/a\u003e\n\nThis application is protected by a MIT license: [LICENCE](../LICENSE).\n\n## Contribute \u003ca name=\"contribute\"\u003e\u003c/a\u003e\n\nBefore making a pull request, don't forget to run these commands (requires Task and Docker Compose):\n\n```bash\ntask ci\ntask test\n```\n\nNote: you can run these commands without Task, have a look to the [Taskfile.yaml](Taskfile.yaml) file to see which commands will run.\n\n## Changelog \u003ca name=\"changelog\"\u003e\u003c/a\u003e\n\nSee the [changelog](CHANGELOG.md).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbastien70%2Fdbsaver","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbastien70%2Fdbsaver","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbastien70%2Fdbsaver/lists"}