• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

access to other sites from one subdomain?

C

castles

Guest
At work we use a custom content management system that I have primarily built. Most of the sites are running off the same server.

What I would really like to do is modify it so that the admin section for the cms is located in one place. What tends to happen is we have lots of different versions of the admin section and its a real pain to update them all.

What I have done is created a subdomain and I can login and modify pages from the cms because it is setup to modify different mysql databases.

The problem I'm having is reading directories and uploading files. I want the user to be able to upload a file in the cms and it puts the file in a directory for the site they are currently editing.

Is it possible read and write from a subdomain to other virtual hosts?

I have been trying to user symbolic links to the other domains directories. The links are working fine for root but the ftp user and apache user can't read the files from those directories.

Thanks
 
ok, so I worked out I need to use symbolic links and I managed to get that working. Yay.

The problem I'm having is that I can't browse the files in that directory yet. I can see them in the browser but when I open a directory handle to the symlink I get an open_basedir restriction error.

I tried setting open_basdir to none in the vhost.conf file but it doesn't seem to do anything. When I do a phpinfo() it is still set to /home/httpd/vhosts/[domain name]/subdomains/marc/httpdocs:/tmp

I read somewhere that setting the open_basedir restriction in the vhosts.conf for the subdomain it won't work so I added it to the vhost.conf for the main domain. Does this mean it will filter through to the subdomains?

Have I missed something?

Thanks,

Marc
 
ok, another update.. I managed to set the base_dir for the main httpdocs directory but not for the subdomains.
 
Back
Top