Forcing database to same server as site

Discussion in 'Developers' Forum' started by choong, Mar 29, 2019.

  1. choong

    choong New Member

    We have a multi-server setup on which we create hosting packages through the API. The 'controller software' has a list of available servers and ensures there is room on a server. If server A is full, it creates the hosting package on server B, etc. We don't create a database by default - we leave that to the customer.

    If a hosting package gets created on server B, we always want the customer's database to also be on server B. However, the limits template contains all available database servers so at the moment the user can select a database on a different server, which we don't want. We could use (additional) limits templates, but that causes extra maintenance work.

    We are considering sending a PR to a checkbox somewhere, to always force the db to the same server as the site.

    @till Would you merge such a feature in upstream? Do you agree it is a good way to fulfill the requirement?

    If so, would you prefer this checkbox to be on the server config, or in the limits template? Or do you have other ideas?

    Thanks a lot in advance.
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    I will merge it if it's implemented properly.

    I would prefer it to be in the limits template.

Share This Page