[Twisted-web] xmlrpc server daemon

Jean-Paul Calderone exarkun at divmod.com
Wed Feb 8 08:01:09 MST 2006

On Wed, 08 Feb 2006 11:14:12 -0200, Gustavo Rahal <gustavo at grahal.net> wrote:
>How do I make my xmlrpc server a daemon?
>The code that starts the server is:
>r = rmsWebServices()
>reactor.listenTCP(7080, server.Site(r))
>What should I change?

Twisted comes with a daemonizer, `twistd'.  Rewrite the above as:

    from twisted.application import service, internet

    application = service.Application("RMS Web Service")
    website = internet.TCPServer(7080, server.Site(r))

And then run it using "twistd -y <filename>".


More information about the Twisted-web mailing list