summaryrefslogtreecommitdiff
path: root/source4/web_server/swat/__init__.py
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2008-05-28 08:11:05 +1000
committerAndrew Bartlett <abartlet@samba.org>2008-05-28 08:11:05 +1000
commit51ae2302a68033b1b79a4ebc8d4cbab64adcf843 (patch)
treed8b1af54efe4ec70607ef2bcbd873c2cd667d894 /source4/web_server/swat/__init__.py
parent5d0d239d1ab826c91839a603f93d2c0061658888 (diff)
parent52b230141b5ad9f317f97e7d257703614bab3985 (diff)
downloadsamba-51ae2302a68033b1b79a4ebc8d4cbab64adcf843.tar.gz
samba-51ae2302a68033b1b79a4ebc8d4cbab64adcf843.tar.bz2
samba-51ae2302a68033b1b79a4ebc8d4cbab64adcf843.zip
Merge branch 'v4-0-test' of ssh://git.samba.org/data/git/samba into 4-0-abartlet
It seems the format of main.mk changed in my sleep... Conflicts: source/main.mk (This used to be commit 56f2288e4f4f1aa70d11fc5f118458baf5803627)
Diffstat (limited to 'source4/web_server/swat/__init__.py')
-rw-r--r--source4/web_server/swat/__init__.py27
1 files changed, 27 insertions, 0 deletions
diff --git a/source4/web_server/swat/__init__.py b/source4/web_server/swat/__init__.py
new file mode 100644
index 0000000000..e0d85dbe2c
--- /dev/null
+++ b/source4/web_server/swat/__init__.py
@@ -0,0 +1,27 @@
+#!/usr/bin/python
+
+# Unix SMB/CIFS implementation.
+# Copyright © Jelmer Vernooij <jelmer@samba.org> 2008
+#
+# Implementation of SWAT that uses WSGI
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+#
+
+def SWAT(environ, start_response):
+ status = '200 OK'
+ response_headers = [('Content-type','text/plain')]
+ start_response(status, response_headers)
+ return ['Hello world!\n']
+