WordPress 本地环境部署线上环境标准化流程(手动版)
WordPress 本地环境部署线上环境标准化流程(手动版)
目录
Local Git Repository
Rsync wp-content/upload
Import Database
755 permission wp-content/upload
一. Git Local
local repository
git push
remote server
git fetch
git merge
二. Rsync wp-content/upload file
rsync --ignore-existing -vzrh source target
-v : verbose
-r : copies data recursively (but don’t preserve timestamps and permission while transferring data
-a : archive mode, archive mode allows copying files recursively and it also preserves symbolic links, file permissions, user & group ownerships and timestamps
-z : compress file data
-h : human-readable, output numbers in a human-readable format
三. Import Database
export local database
change URL
remote import database
四. Remote Server Permission
chmod -r 755 wp-content/uploads