Linux Shell script WordPress Site Mirror Script for Failover Server
Оплачивается при доставке
The objective of this shell script is to create a mirror image of a WordPress site on a second duplicate server, which will serve as a failover option. The script will utilize technologies such as rsync to synchronize web directory files and perform a database copy. It should also support logging and notification features to report any sync or database copy errors. The script will be scheduled to run at least once daily.
Script Configuration Options:
- Database name
- Database user
- Database password
- Source Web Directory:
- Web directory location
Destination Web Directory:
Web directory location
Email address(es) to receive notifications in case of errors or completion
Estimated Script Workflow:
- Connect to the source database using the provided source database credentials.
- Create a backup of the source database.
- Connect to the destination database using the provided destination database credentials.
- Drop the existing destination database if it exists.
- Restore the source database backup to the destination database.
- Connect to the source server using SSH and rsync the web directory to the destination server's web directory location.
- Monitor the rsync process for any errors and log the progress.
- Send a notification email if any errors occur during the rsync process or database copy.
- Log the script's execution details, including success and failure status, in the specified log file.
- Ensure that the script is executed with appropriate permissions to access the necessary files and directories.
- Use secure methods to store and retrieve sensitive information such as database credentials.
- Validate all user input to prevent any potential security vulnerabilities.
- Test the script thoroughly before deploying it in a production environment.
- Schedule the script to run at least once daily using a cron job or a similar scheduler.
Can make use of WP CLI
Note: This brief provides an overview of the desired shell script's functionality and configuration options. The actual implementation may require additional steps or modifications based on the specific server setup and requirements.
ID проекта: #36689437
40 фрилансеров(-а) готовы выполнить эту работу в среднем за $144
WORDPRESS EXPERTS! We are working on wordpress since last 11 years. We could do it. Could we discuss in details over chat now? Best Regards Techwelfare
Hello, I understood the project but have few doubts, please text me so i can clear all my questions right away and to confirm my skills and expertise you can have a look to my profile