-
-
Notifications
You must be signed in to change notification settings - Fork 243
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
Multi tenancy in worker mode #219
Comments
One way to do this would be to have "named workers" so you can have more than one worker configured in global options, then refer to a specific one in the site block. |
Thank you for the answer, the documentation doesn't seem to mention named workers, though. I can't seem to find it in the source either, looking at Lines 41 to 48 in eca8cc7
So I take it this has to be implemented first? |
Multi-workers is already supported, but not @francislavoie proposal. It would be nice to add it! |
Okay, I'll see if I can implement it when I'm done with ext-imap and ext-ldap in spc. The option to run multiple sites is crucial - luckily it's possible without workers for now so the switch will be easy later. |
This hack should also do the trick (as a workaround): {
frankenphp {
worker /var/www/staging/public/index.php
worker /var/www/prod/public/index.php
}
}
staging.example.com {
root /var/www/staging/public/
// ...
}
prod.example.com {
root /var/www/prod/public/
// ...
} And if you need to share some files between prod and staging, use symlinks. WDYT? |
Oh that's smart, thank you. Will definitely add it to the documentation later. I've got php-imap and php-ldap to compile now so they should be ready for the static binaries soon, but I'm not sure what the best place is to enquire whether php-imap is thread safe or not. The GitHub repository or a mailing list? Edit: It's not thread safe and will be dropped from php. |
is there a timeframe for ldap ? |
It's already merged. |
For reference: #203 |
so it will be in the next rc and/or in 1.0 final ? |
it's already in the current rc...? are you not using the static version, but the docker version perhaps? you need to check the documentation how to install ldap then. It's just one extra line |
i am using the 1.0.0.rc2 static musl version from the release page. the phpinfo() page does not show a ldap section |
You're right, it's not in current RC yet. Sorry for the confusion. You can fork this repo and manually build it with docker, or trigger a workflow. I'd upload you a binary, but I'm not sure if that's discouraged here since authenticity couldn't be verified. |
no problem, i can wait to official release |
In the documentation it's specified that you can pass env variables to the worker. Is it also possible to spawn workers per-vhost? E.g.
Or even spawn two entirely different workers?
The text was updated successfully, but these errors were encountered: