Two apps same server same Database - Forum

Forum Navigation
You need to log in to create posts and topics.

Two apps same server same Database

Hello,

I have this situation where I developed an app that interacts with a Database using NeoPHP.

Now, I need a separate, different app against the same Database, and I also need to use NeoPHP.

I am assuming that:

  1. Only one instance of PHP can be running on the server, with a given root directory.
  2. In that root directory I can have only one app.

How should I proceed to have more than one app running on the same server?

Thanks in advance

 

Best Regards

 

@egodyla I don't understand very well the problem.
If you are using MySQL or SQL Server you should find no problem at all.
You can deploy your apps in different folders or subdomains and still use the same database.
It's also possible to use a single SQLite database for both apps, you just only need to be more careful.

Regards.

Hi Luis, thank you so much..

Sorry for not being clear enough, I will try to explain myself better:

For an app X I start the NeoPHP Server with the root directory of App X, and the config.php for App X.

While I am running App X,  I need to run also App Z. Can I start a new instance of NeoPHP Server and specify another config.php for App Z? I think it is not possible...

So, if I have only one instance of NeoPHP server running, I can merge both config.php files into one and not using localhost/#!/Landing as the start page, but the folder on the disk. Is that the way to go?

Thanks in advance and I apologize for my limited understanding...

 

@egodyla just install / use each app from its own folder or subdomain.
If you are working on localhost start your server using the parent directory and in the URL use the complete one.
Example: Place App X on c:\myrootfolder\x and App Z in c:\myrootfolder\z
Then start neoPhp server or your own server using c:\myrootfolder as the root folder.
To execute App X use the URL: http://localhost/x and for App Z http://localhost/z

And thats all. Use separate folders, same database.

Thank you Luis!

I appreciate!!

Open chat
1
Do you need more info?
Hi, do you have any doubt?