Here's my latest draft: https://github.com/agordon/Dancer/blob/topic/deployment_pod/lib/Dancer/Deplo... It's pretty much ready (from my narrow Apache point-of-view). 1. I have verified all the different apache configurations - they all work (barring any typos). 2. included is a section on serving static files directly (requested by someone on the mailing list). 3. Added a section on load-balancing in apache using mod_proxy_balancer 4. Elaborated about deploying multiple Dancer applications on same server. 5. Simplified (IMHO) the configuration Stanzas - removed fluff like "ServerName" etc. which is not always relevant. 6. Change some of the Apache configuration examples, the old POD show changing the "documentroot" - that's not needed. 7. with NGINX+Proxy, simplified the example, removed fluff, and made it use TCP socket instead of a unix socket - to be more in line with the other examples. 8. Other stuff - copied as-is. I'm not familiar with those things (e.g. PerlBal, Balance, UBic, etc.) - so proofreading is still required. Comments and corrections are welcomed, -gordon
Great job! One thing though and i could be wrong here so maybe someone more experienced will speak up. Anyway the point is with nginx Unix sockets are kinda awesome. Seems a shame to not have an example listed for them. On 10/11/2011 8:57 AM, "Assaf Gordon" <gordon@cshl.edu> wrote:
Here's my latest draft:
https://github.com/agordon/Dancer/blob/topic/deployment_pod/lib/Dancer/Deplo...
It's pretty much ready (from my narrow Apache point-of-view).
1. I have verified all the different apache configurations - they all work (barring any typos).
2. included is a section on serving static files directly (requested by someone on the mailing list).
3. Added a section on load-balancing in apache using mod_proxy_balancer
4. Elaborated about deploying multiple Dancer applications on same server.
5. Simplified (IMHO) the configuration Stanzas - removed fluff like "ServerName" etc. which is not always relevant.
6. Change some of the Apache configuration examples, the old POD show changing the "documentroot" - that's not needed.
7. with NGINX+Proxy, simplified the example, removed fluff, and made it use TCP socket instead of a unix socket - to be more in line with the other examples.
8. Other stuff - copied as-is. I'm not familiar with those things (e.g. PerlBal, Balance, UBic, etc.) - so proofreading is still required.
Comments and corrections are welcomed, -gordon _______________________________________________ Dancer-users mailing list Dancer-users@perldancer.org http://www.backup-manager.org/cgi-bin/listinfo/dancer-users
This document is just just awesome ! Thank you for putting it together, nice work. I look forward to have it released On 9 November 2011 22:57, Assaf Gordon <gordon@cshl.edu> wrote:
Here's my latest draft: https://github.com/agordon/Dancer/blob/topic/deployment_pod/lib/Dancer/Deplo...
It's pretty much ready (from my narrow Apache point-of-view).
1. I have verified all the different apache configurations - they all work (barring any typos).
2. included is a section on serving static files directly (requested by someone on the mailing list).
3. Added a section on load-balancing in apache using mod_proxy_balancer
4. Elaborated about deploying multiple Dancer applications on same server.
5. Simplified (IMHO) the configuration Stanzas - removed fluff like "ServerName" etc. which is not always relevant.
6. Change some of the Apache configuration examples, the old POD show changing the "documentroot" - that's not needed.
7. with NGINX+Proxy, simplified the example, removed fluff, and made it use TCP socket instead of a unix socket - to be more in line with the other examples.
8. Other stuff - copied as-is. I'm not familiar with those things (e.g. PerlBal, Balance, UBic, etc.) - so proofreading is still required.
Comments and corrections are welcomed, -gordon _______________________________________________ Dancer-users mailing list Dancer-users@perldancer.org http://www.backup-manager.org/cgi-bin/listinfo/dancer-users
On 9 November 2011 22:57, Assaf Gordon <gordon@cshl.edu> wrote:
Here's my latest draft: https://github.com/agordon/Dancer/blob/topic/deployment_pod/lib/Dancer/Deplo...
It's pretty much ready (from my narrow Apache point-of-view).
1. I have verified all the different apache configurations - they all work (barring any typos).
2. included is a section on serving static files directly (requested by someone on the mailing list).
3. Added a section on load-balancing in apache using mod_proxy_balancer
4. Elaborated about deploying multiple Dancer applications on same server.
5. Simplified (IMHO) the configuration Stanzas - removed fluff like "ServerName" etc. which is not always relevant.
6. Change some of the Apache configuration examples, the old POD show changing the "documentroot" - that's not needed.
7. with NGINX+Proxy, simplified the example, removed fluff, and made it use TCP socket instead of a unix socket - to be more in line with the other examples.
8. Other stuff - copied as-is. I'm not familiar with those things (e.g. PerlBal, Balance, UBic, etc.) - so proofreading is still required.
Comments and corrections are welcomed,
Very nice. But, I don't get why is it that I am able to run several Starman powered Dancer apps behind Apache front-end without every having declared the behind_proxy setting in the config file. -- Puneet Kishor
Puneet Kishor wrote, On 11/09/11 18:47:
Very nice. But, I don't get why is it that I am able to run several Starman powered Dancer apps behind Apache front-end without every having declared the behind_proxy setting in the config file.
Indeed interesting - it didn't work for me (and for several others, based on recent emails). The only problem with not enabling "behind_proxy" is that "request->uri_for" and "request->uri_base" return links that start with "http://127.0.0.1:3000" . Perhaps you have some special Apache configuration ? and proxying not through TCP ? or perhaps you're only using relative links ?
On Nov 9, 2011, at 5:59 PM, Assaf Gordon wrote:
Puneet Kishor wrote, On 11/09/11 18:47:
Very nice. But, I don't get why is it that I am able to run several Starman powered Dancer apps behind Apache front-end without every having declared the behind_proxy setting in the config file.
Indeed interesting - it didn't work for me (and for several others, based on recent emails).
The only problem with not enabling "behind_proxy" is that "request->uri_for" and "request->uri_base" return links that start with "http://127.0.0.1:3000" .
Perhaps you have some special Apache configuration ? and proxying not through TCP ? or perhaps you're only using relative links ?
OK. That makes sense. I am not using request->uri_* at all. I actually have fully qualified links always, and I set them up in my config files like so appuri: "...." liburi: "...." and then, in my templates, [% appuri %]/foo etc. No wonder I never experienced this as an issue. On the other hand, I've had countless other issues with deployment, and the only one that has worked for me is Starman behind Apache proxy. As a result, I now I have 12 Dancer apps on my iMac with 10 Starman workers on each, so my process list is polluted with 120 of Perl processes. At some point I have to revisit running all this via mod_perl or mod_psgi or whatever. I never could get fast_cgi to work with Apache. -- Puneet Kishor
Puneet Kishor wrote, On 11/09/11 19:14:
On Nov 9, 2011, at 5:59 PM, Assaf Gordon wrote:
Puneet Kishor wrote, On 11/09/11 18:47:
Very nice. But, I don't get why is it that I am able to run several Starman powered Dancer apps behind Apache front-end without every having declared the behind_proxy setting in the config file.
Perhaps you have some special Apache configuration ? and proxying not through TCP ? or perhaps you're only using relative links ?
OK. That makes sense. I am not using request->uri_* at all. I actually have fully qualified links always, and I set them up in my config files like so
appuri: "...." liburi: "...."
and then, in my templates, [% appuri %]/foo etc.
No wonder I never experienced this as an issue. On the other hand, I've had countless other issues with deployment, and the only one that has worked for me is Starman behind Apache proxy. As a result, I now I have 12 Dancer apps on my iMac with 10 Starman workers on each, so my process list is polluted with 120 of Perl processes.
Would you mind sharing some of the issues ? might help with the documentation, recommending what to avoid.
At some point I have to revisit running all this via mod_perl or mod_psgi or whatever.
IMHO, "mod_perl" + Plack::Handler::Apache2 should be avoided until the issue of multiple Dancers is resolved. I haven't tried "mod_psgi" yet.
I never could get fast_cgi to work with Apache.
The current documentation for Apache+FastCGI is incorrect (or at least incomplete). The examples included in my new POD are working - guaranteed! (and if you find errors, please let me know). -gordon
participants (4)
-
Assaf Gordon -
damien krotkine -
Puneet Kishor -
Sarah Fuller