摘自:
01
02
python
03
127.0.0.1:9001
04
05
>
06
07
08
09
4
10
8
11
1
12
2000
13
512
14
256
15
192
16
17
18
uwsgi配置檔案中的引數也可以在命令列通過uwsgi指定,配置檔案除了xml格式外,還可以寫成ini格式的,軟體包安裝完畢後在
/usr/share/doc/uwsgi/examples/conffile目錄下會有一些xml和ini格式配置檔案的例子。
wsgi_configuration_module.py指令碼內容
01
#!/usr/bin/python
02
import
os
03
import
sys
04
)
05
os.environ[
'python_egg_cache'
] =
'/var/www/example/.python-egg'
06
07
status =
'200 ok'
08
output =
'hello world!'
09
response_headers = [(
'content-type'
,
'text/plain'
),
10
(
'content-length'
, str(len(output)))]
11
start_response(status, response_headers)
12
return
[output]
啟動uwsgi
1
除了直接用uwsgi命令啟動外,還可以用init.d下的指令碼啟動,
不過需先修
改/etc/default/u
wsgi中預設配置檔案的路徑,然後通過/etc/init.d/uwsgi start啟動
1
#inherited_config=/usr/share/uwsgi/conf/default.ini
2
乙個PlaySound示例
using system using system.collections using system.componentmodel using system.runtime.interopservices internal class helpers dllimport winmm public s...
xml的乙個示例
function.h cstring openfile cstring cstring getcontext cstring,int,int void str2array cstring struct xmlnode function.cpp include include include incl...
乙個示例儲存過程
create or replace procedure bm add p id varchar,p name varchar is v count number begin 檢查輸入引數是否為空 if p id is null or p name is null then p out 輸入的值為空!...