Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Smisk and Nginx
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  3 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Atilla  
View profile  
 More options Mar 30 2009, 1:40 pm
From: Atilla <theati...@gmail.com>
Date: Mon, 30 Mar 2009 10:40:56 -0700 (PDT)
Local: Mon, Mar 30 2009 1:40 pm
Subject: Smisk and Nginx
I've recently found out about Smisk and I'm very curious to experiment
with it. I've a small project going fairly well for now, but I want to
host it on a host where my server is Nginx.

Now, Nginx supports fcgi, however it doesn't spawn or control
processes itself, which is a small problem. I can't seem to find a
consistent way people spawn FCGI processes, especially Python
processes. I was experimenting with spawn-fcgi, which is essentially
the code from lighty's fcgi module, but I can't seem to make it to run
the example applications.

I've been wondering if there are any other suitable C or Python based
tools or libraries I could use to run a concurrent FCGI server,
somehting that won't be too heavy of a dependency, in comparision to
Smisk and Nginx?


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Rasmus Andersson  
View profile  
 More options Mar 30 2009, 4:33 pm
From: Rasmus Andersson <ras...@flajm.com>
Date: Mon, 30 Mar 2009 22:33:42 +0200
Local: Mon, Mar 30 2009 4:33 pm
Subject: Re: Smisk and Nginx
Hi Atilla!

Actually, you can start a smisk process as a stand-alone (FastCGI)
server. Create this file and save it as process.py:

from smisk.core import *
class MyApp(Application):
  def service(self):
    self.response('hello')

from smisk.util.main import main
main(MyApp)

Now, try running the script with --help:

$ python process.py --help
Usage: process.py [options]

Options:
  -h, --help            show this help message and exit
  -d PATH, --appdir=PATH
                        Set the application directory. Not set by default.
  -b ADDR, --bind=ADDR  Start a stand-alone process, listening for FastCGI
                        connection on ADD, which can be a TCP/IP address with
                        out without host or a UNIX socket (named pipe on
                        Windows). For example "localhost:5000",
                        "/tmp/my_process.sock" or ":5000". Not set by default.
  -c N, --forks=N       Set number of childs to fork. Not set by default.
  --debug               sets log level to DEBUG

You want to start your process.py with at least the --bind argument:

$ python process.py --bind=127.0.0.1:5000

In production, it's a good idea to have your Smisk server(s) managed
by a process manager. If you're on Debian, that means an
init.d-script. On OS X it's a launchd-script, and so on.

--
Rasmus Andersson

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Atilla  
View profile  
 More options Mar 30 2009, 7:03 pm
From: Atilla <theati...@gmail.com>
Date: Tue, 31 Mar 2009 01:03:42 +0200
Local: Mon, Mar 30 2009 7:03 pm
Subject: Re: Smisk and Nginx
Hi Rasmus,

Thanks, I've completely missed that out. I just assumed in the hurry
that the framework expects an already established FCGI environment,
due to the initial error message I saw and didn't really look any
further in the code to check.

This is completely enough for what I need and quite the good start, thank you.

2009/3/30 Rasmus Andersson <ras...@flajm.com>:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »