Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Running multiple environments at once? #127

Closed
DubbleClick opened this issue Sep 10, 2023 · 3 comments
Closed

Running multiple environments at once? #127

DubbleClick opened this issue Sep 10, 2023 · 3 comments

Comments

@DubbleClick
Copy link

DubbleClick commented Sep 10, 2023

This may not be possible, but I'd like to check what the recommended way to replicate this is moving from apache + fpm to roadrunner.

I currently have 4 vhosts in my apache config, one, two, three and four. Each points to the same /var/www/app/public directory with APP_ENV one|two|three|four. Since php-fpm boots the kernel with the current requests environment variables, all is well.

Now, is it possible to boot four workers for each of the four app environments with roadrunner and have it handle an incoming request to a specific host with its respective environment worker?

The only way I can currently see how to set it up is running four roadrunner instances on different ports, passing the respective APP_ENV at startup and using apache or nginx as a reverse proxy.

Actually, to complicate matters a little more, each of these four environments uses mercure and as far as I can see, a mercure support request for roadrunner was closed in favour of centrifugo.

Do I really have to setup four roadrunner servers, four mercure servers and apache or nginx to piece it all together?

@DubbleClick
Copy link
Author

Actually this feature request was raised in #63 so I suppose it's not possible. Running a reverse proxy and one rr server per tenant is the best option?

@iborysenko
Copy link
Contributor

Hi, using more than one RR config for your case is possible.
In my project, we have two configs. one for HTTP workers, and another one for JOBS.
So you can start it in one docker container using different ports.

@DubbleClick
Copy link
Author

Closing, since I moved to Caddy/FrankenPHP and this doesn't appear to be possible or planned.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants