Skip to content

xN8Tx/strapi-v5-database-backup

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

✨ Strapi Database Backup ✨

Export and import your database backup from Strapi UI

🚀 Installation

Install the plugin using your favorite package manager:

npm install strapi-v5-database-backup

or

yarn add strapi-v5-database-backup

📦 Requirements

To correct work this plugin you need to install additional package to get access to manipulate database on your machine:

  • If you use SQLite:
// use package manager for your OS
sudo apt install sqlite3
  • If you use MySQL:
// use package manager for your OS
sudo apt install mysql-client mariadb-connector-c

To correct work this plugin you need to add to environment variables to get access to manipulate database on your machine:

DATABASE_ROOT_USER=your_root_user
DATABASE_ROOT_PASSWORD=your_root_password
  • If you use PostgreSQL:
// use package manager for your OS
sudo apt install postgresql

It's build for Strapi v5. It has been tested to work with v5.4.2 and I assume it should keep working with later versions.

âš¡ Features

  • Create database and public folder backups
  • Restore database and public folder from backup
  • Manage backups in Strapi UI

✋ Need to know

  • Your data you can find in src/extentions/strapi-v5-database-backup folder.

  • This plugin shut down your strapi after restore data, this is because you need to restart your strapi to apply data to work. I doesn't find how i can do it in Strapi, so if you install this plugin and want restore data in production, you need to setup docker-compose with restart: always or use pm2.

  • This plugin also restart your strapi in development mode when you create or restore data, this is because the plugin files create in src folder what toggle basic restore functions.

  • This plugin work with: PostgreSQL, MySQL and SQLite.

🌟 Usage

Add the plugin to your Strapi project:

// config/plugins.js
module.exports = () => {
 "strapi-v5-database-backup": {
    enabled: true,
  },
}

After that your plugin will be finally added to your Strapi project. You can find it in strapi sidebar.

About

💾 Export and import your database backup from Strapi UI

Topics

Resources

License

Stars

Watchers

Forks