Sunday, October 31, 2010

Old Nabble - Turbogears General - how to return csv data?

Old Nabble - Turbogears General - how to return csv data?: "e.g. like this

@expose(content_type='text/csv')
def csv(self):
stream = StringIO()
writer = csv.writer(stream, dialect='excel')
writer.writerow(['Spam'] * 5 + ['Baked Beans'])
writer.writerow(['Spam', 'Lovely Spam', 'Wonderful Spam'])
output = stream.getvalue()
stream.close()
return output

For creating real Excel files you can use this:

http://www.python-excel.org

- Sent using Google Toolbar"

Tuesday, October 19, 2010

HOWTO patch Nexenta (open source)

> I like the built in patcher in the Openfiler GUI. I’m not sure how Nexenta does patching.

Just run “$ setup appliance upgrade nms” to upgrade the Web UI or “$ setup appliance upgrade” to upgrade the base OS software in Nexenta Community Edition. Both commands should be run as ‘root’.

$ setup appliance upgrade nms

$ setup appliance upgrade

http://greg.porter.name/wordpress/?p=590

Tuesday, October 12, 2010

TurboGears 2.1 Standard Installation

$ virtualenv --no-site-packages -p python2.6 tg2env
$ cd tg2env/
$ source bin/activate
(tg2env)$ easy_install -i http://www.turbogears.org/2.1/downloads/current/index tg.devtools
(tg2env)$ paster quickstart example
(tg2env)$ cd example/
(tg2env)$ python setup.py develop
(tg2env)$ nosetests
(tg2env)$ paster setup-app development.ini
(tg2env)$ paster serve development.ini
(tg2env)$ deactivate

Upgrading TurboGears

easy_install -U -i http://www.turbogears.org/2.1/downloads/current/index tg.devtools

Thursday, October 7, 2010

Logging to a Database with Rsyslog

rsyslog and postgres

in reference to:

"Logging to a Database with Rsyslog"
- Logging to a Database with Rsyslog LG #172 (view on Google Sidewiki)