Jump to content

Advice needed for site


Recommended Posts

Hey guy's have a few friends that need an admin panel to manage there clients and information


So i created a script and did the panel ..but im debating on how do i share this.


i created a domaine


and database


but if i have 3 guy's that need it for there own clients.Do i create sub domains for each and individuel databases or one database with like a RepID field in the tables to filter each login's and clients that are associated to this admin...


or do i create a database for each so it can be safer and less heavy in long terme..


if so is there like a script that i can do that can create a sub domain and database and insert all the tables and files...lol or is it pushing it..


Thx Guy's

Link to comment
Share on other sites

Well, do you want to support one application that can handle all the clients' needs, or do you want to customize and maintain multiple copies separately?


One database costs more work now (adding that ID) but less work later (one codebase for everyone). Separate databases is less work now (make copies) and more work later (fix the same bug multiple times).

  • Like 1
Link to comment
Share on other sites

This is an extremely complicated question to answer and impossible with the minimal information you provided.  While there are certainly development implications to your question, there could be an equal amount of DevOps capability required.    


The general term for setup and configuration of an environment or service, is called "Provisioning".  Certainly you can create a series of scripts that do this for you and put an environment in a known state.  There are all sorts of DevOps tools out there like Chef, Puppet, Salt and Ansible that do "orchestration" of environments and are built to handle whatever you might need.  There's also Docker, which has a lot of features that could handle the isolation of separate computing environments.


Typically the way this is done is that you have not only a copy of the database, but a separate copy of the code. While that is not strictly necessary, and adds to the redundancy, it also provides isolation of an environment.   So you could have customizations or modules for customer A, that customer B does not have.  


Otherwise you will have to have some separate bootstrapping code that reads a separate environment for each person.  


In general, yes, one way to handle this is to have separate virtual host configurations and use a subdomain.  





Each user gets a different directory, with different db user/pw and database name.


Doing this well, writing all the code to make it happen, and testing is all additional work, but by the same token, you will have extra code and complexity involved in every database query you have if you need to segment all your data by user.


Ultimately, if this could develop into a business where you are providing "Software as a service"  then it's probably better to take the DevOps approach and separate the environments, but then you have more system administration to deal with.  If it's probably just going to be these 3 guys, you are probably better off just maintaining one system configuration and putting in the code that relates all the data to a specific user.

  • Like 1
Link to comment
Share on other sites

This thread is more than a year old.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.