https://github.com/dulingkang/backup-wordpress-shell
shell about backup wordpress folder and database.
https://github.com/dulingkang/backup-wordpress-shell
Last synced: about 1 year ago
JSON representation
shell about backup wordpress folder and database.
- Host: GitHub
- URL: https://github.com/dulingkang/backup-wordpress-shell
- Owner: dulingkang
- License: mit
- Created: 2016-08-23T06:30:15.000Z (almost 10 years ago)
- Default Branch: master
- Last Pushed: 2016-08-23T07:01:29.000Z (almost 10 years ago)
- Last Synced: 2025-03-29T08:23:02.228Z (about 1 year ago)
- Language: Shell
- Size: 3.91 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# backup-wordpress-shell
shell about backup wordpress folder and database.
You need to change the shell:
- 1. sourceFolder is the folder you want to backup, such as your wordpress folder:
```
/home/www/wordpress
```
- 2. backDir is the folder your backup files in, such as:
```
/var/backup
```
- 3. mysql config
input your wordpress db username password and dbname,
```
user="dbuser"
password="yourdbpassword"
dbname="wordpress"
```
the destination export sql folder is:
```
sqlPath="$destDir/wordpress.sql"
```
## process
- destDir is automatic created use this format: "wordpress160823", the sourceFolder will copy into this folder, and wordpress.sql also exported to this folder.
- And last, destDir will gzip to this format: "wordpress160823.tar.gz", the follder "wordpress160823" will be removed"