Lock Symlink Ownership?

  • So I have a site that is using a symlink'd folder to another location. More accurately the htdocs folder is a symlink to another folder under the /home directory. When I change the owner of the symlink, everything works. However, when there is any kind of update to the imscp control panel, the ownership of that symlink is reverted back to vuXXXX and the symlink no longer works. I have also tried a structure of /var/www/vir..../htdocs/link thinking it was just the htdocs folder. This did not give the results as intended, as any update causes any file or folder to be reverted to vuXXXX.


    My question is this, is there a way to prevent imscp from reverting the ownership of the file/folder, or possibly an alternative solution to accomplish this?


    Thanks in advance!


    [edit]
    I know I'm using an out-dated version (1.1.18), so if upgrading is the solution that would be fine. I have just been really paranoid about upgrading with some of the changes, and that this is a "live" server.

  • Hello ;


    i-MSCP is for shared hosting environments where customers are confined in their own homedir, with their own permissions. Thus, a customer is not allowed to set other user/group on its files than those which were assigned to it. This explain why the installer automatically resets the permissions on update. We will not provide any feature allowing to override default permissions. You can always override the permissions by yourself using a listener which will change the permissions on the specified files once the update is done.

    badge.php?id=1239063037&bid=2518&key=1747635596&format=png&z=547451206

  • Thanks for the info.


    I really don't know how to go about setting up a listener. So I symlinked the htdocs to another folder in it's root area that vuXXXX has access to, and used .htaccess to redirect/rewrite to another symlink that has the correct permissions.


    If you were curious about why I needed this, is that this particular site is updated by a Source Code Management program (like GitHub). So when there are changed pushed, it updates the live site without having to manually upload there.