Dev environment
Last updated
Was this helpful?
Last updated
Was this helpful?
has own db and own copy of the uploads folder (to allow write new images during development)
has own db and a link to dev’s uploads folder (with write permissions, because code in the dev group on the server)
(as a root user)
(for dev & code)
mysqldump -u root -p{x} {originDb} | mysql -u root -p{x} {targetDb}
change site url & home url in the options table
replace the old urls to the new in all tables (e.g. via the Better Search Replace plugin)
(for dev only)
rm /home/dev-angama/www/html/wp-content/uploads/* -rf
cp /home/angama/www/html/wp-content/uploads/* /home/dev-angama/www/html/wp-content/uploads -r (will take some time, maybe 15min)
chown dev-angama:dev-angama /home/dev-angama/www/html/wp-content/uploads -R
sudo find /home/dev-angama/www/html/wp-content/uploads -type d -print0 | xargs -0 sudo chmod g+w (adding a writing capacity to the group, so the code user will be able to write)
In site settings (admin area, for dev & code)
change Google Analytics code to dev (!important)
enable Staging mode with http protecting
in WP General settings change the client email to another to avoid getting them notified about technical issues on Code/Dev