On Apr 26, 1:32 pm, SamDonaldson <[EMAIL PROTECTED]> wrote:
> Hello,
>
> I have a quick question on how to run multiple paster servers. I have
> a lighttpd/scgi configuration. In my production.ini file, I have the
> following:
>
> [server:main]
> #use = egg:Paste#http
> #host = 0.0.0.0
> #port = 5000
> use = egg:PasteScript#flup_scgi_thread
> host = 127.0.0.1
> port = 4000
>
> Now, i only ever start one of these listening on port 4000, and
> lighttpd is configured to direct requests to port 4000. This is
> highly suboptimal for concurrent request benchmarking etc.. Is the
> recommended way to start more paster servers to modify the
> production.ini file? Should I specify more ports? If so, how do I do
> that. Or do I start more paster servers on the command-line
> listening on different ports? I'd imagine I have to change
> lighttpd.conf to point to all of these ports then.
>
> Any help would be appreciated.
>
> Thanks,
> Sam
this is my demo project config
u can use this command start main at 5000, main2 at 5002
paster serve --reload development.ini --server-name main
paster serve --reload development.ini --server-name main2
#
# example - Pylons development environment configuration
#
# The %(here)s variable will be replaced with the parent directory of
this file
#
[DEFAULT]
debug = true
# Uncomment and replace with the address which should receive any
error reports
#email_to = [EMAIL PROTECTED]
smtp_server = localhost
error_email_from = [EMAIL PROTECTED]
[server:main]
use = egg:Paste#http
host = 0.0.0.0
port = 5000
[app:main]
use = egg:example
full_stack = true
cache_dir = %(here)s/data
beaker.session.key = example
beaker.session.secret = somesecret
[server:main2]
use = egg:Paste#http
host = 0.0.0.0
port = 5001
[app:main2]
use = egg:example
full_stack = true
cache_dir = %(here)s/data
beaker.session.key = example
beaker.session.secret = somesecret
# If you'd like to fine-tune the individual locations of the cache
data dirs
# for the Cache data, or the Session saves, un-comment the desired
settings
# here:
#beaker.cache.data_dir = %(here)s/data/cache
#beaker.session.data_dir = %(here)s/data/sessions
# WARNING: *THE LINE BELOW MUST BE UNCOMMENTED ON A PRODUCTION
ENVIRONMENT*
# Debug mode will enable the interactive debugging tool, allowing
ANYONE to
# execute malicious code after an exception is raised.
#set debug = false
# Logging configuration
[loggers]
keys = root, example
[handlers]
keys = console
[formatters]
keys = generic
[logger_root]
level = INFO
handlers = console
[logger_example]
level = DEBUG
handlers =
qualname = example
[handler_console]
class = StreamHandler
args = (sys.stderr,)
level = NOTSET
formatter = generic
[formatter_generic]
format = %(asctime)s,%(msecs)03d %(levelname)-5.5s [%(name)s] %
(message)s
datefmt = %H:%M:%S
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"pylons-discuss" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/pylons-discuss?hl=en
-~----------~----~----~----~------~----~------~--~---