Browse Source

set permision after moving ~/.my.cnf

feature/refactor-php
Prabuddha Chakraborty 10 years ago
parent
commit
4e8787effd
  1. 8
      install

8
install

@ -277,16 +277,18 @@ function ee_update()
function ee_update_latest()
{
#Move ~/.my.cnf to /etc/mysql/conf.d/my.cnf
if [ ! -f /etc/mysql/conf.d/my.cnf ]
then
if [ -f ~/.my.cnf ]
then
cp -rf ~/.my.cnf /etc/mysql/conf.d/my.cnf &>> /dev/null
cp ~/.my.cnf /etc/mysql/conf.d/my.cnf &>> /dev/null || ee_lib_error "Unable to copy ~/.my.cnf, exit status " 1
chmod 600 /etc/mysql/conf.d/my.cnf || ee_lib_error "Unable to change permissions for /etc/mysql/conf.d/my.cnf, exit status " 1
else
if [ -f /root/.my.cnf ]
then
cp -rf /root/.my.cnf /etc/mysql/conf.d/my.cnf &>> /dev/null
cp /root/.my.cnf /etc/mysql/conf.d/my.cnf &>> /dev/null || ee_lib_error "Unable to copy ~/.my.cnf, exit status " 1
chmod 600 /etc/mysql/conf.d/my.cnf || ee_lib_error "Unable to change permissions for /etc/mysql/conf.d/my.cnf, exit status " 1
else
echo ".my.cnf cannot be located in your current user or root. Exiting easyengine update process"
exit 100

Loading…
Cancel
Save