Shared WordPress plugin directory concept

Discussion in 'HOWTO-Related Questions' started by Victorius, Apr 28, 2020.

  1. Victorius

    Victorius New Member

    Hi folks,

    I would like to ask for your advices about how I could achive a shared wordpress plugin directory where I would upload the plugins then plugins from that directory would be symlinked to sites if needed.

    Reason is simple, get plugins updated easily on all sites at the same time.

    I'm just wondering about security concers or any other previlige related things which I may miss due to my lack of Unix knowledge.

    How I imagined?

    1. Login ssh as root
    2. mkdir /var/www/wp-plugins
    3. Upload plugin1 to wp-plugins
    4. Create symlink between plugin1 and web1/web/wp-content/plugins/plugin1
    5. Create symlink between plugin1 and web2/web/wp-content/plugins/plugin1
    At step 2 this dir would have root:root chown which seems a bit dangerous. Since all webpages running under different users like web1, web2 I also wondering if every file going to have the right permissions to run.

    Could you help me out with the correct way?

    Sorry if my question does not stick directly to ISPConfig but rather a general Linux question but by using this enviroment I would appricipate a help from this great community.

    Thank you!
  2. nhybgtvfr

    nhybgtvfr Well-Known Member HowtoForge Supporter


    you wouldn't be sym-linking the plugin to sites, you'd be symlinking the sites to the plugin.
    it would be a security nightmare, ideally, all the sites would be running php under their own ids, they'd all need access rights to the shared plugins folder.
    anyone with access to a wordpress backend admin login on one of those site would be able to update the plugin, which would update it on all the other sites, regardless of whether or not the wordpress version and new plugin version combination is compatible on any of those sites.

    if you want an easy way to add a plugin / update a plugin on multiple wordpress sites, in one go, then use something like infinite-wp, mainWP,. or manageWP

Share This Page