From a6a17f2d086a46ce395ce92cf6f54a313af1834e Mon Sep 17 00:00:00 2001 From: Mart Lubbers Date: Thu, 15 May 2014 16:40:06 +0200 Subject: [PATCH] better install and writing to files --- log/2014-05-15.txt | 6 ++++++ program/hypfront/hyper.py | 11 +++++++---- program/hypfront/install.sh | 7 +++++-- program/sites.txt | 15 +++++++++++++++ 4 files changed, 33 insertions(+), 6 deletions(-) create mode 100644 log/2014-05-15.txt create mode 100644 program/sites.txt diff --git a/log/2014-05-15.txt b/log/2014-05-15.txt new file mode 100644 index 0000000..5aa4a1d --- /dev/null +++ b/log/2014-05-15.txt @@ -0,0 +1,6 @@ +TIME: + +http://www.tga.nl/kalender organisatie level. +mail sturen naar pemberton over xforms + +volgende week backend processen diff --git a/program/hypfront/hyper.py b/program/hypfront/hyper.py index 2613481..7eedaf3 100644 --- a/program/hypfront/hyper.py +++ b/program/hypfront/hyper.py @@ -3,10 +3,10 @@ from mod_python import apache, util import feedparser -import pprint import re import urllib - +import subprocess +import os def req_pre_pos(req): req.log_error('handler') @@ -19,14 +19,17 @@ def req_pre_pos(req): HyperFrontend RSS feed POSTREQUEST - Thanks submitting: {}
+ Thanks submitting:
Enter new rss feed
 {}
         
-""".format(args.keys(), args['content'])) +""".format(args)) + os.chdir('/var/www/py/files') + with open('raw_out.txt', 'w') as f: + f.write(str(args)) def req_pre(req): diff --git a/program/hypfront/install.sh b/program/hypfront/install.sh index 46ac56c..148c399 100644 --- a/program/hypfront/install.sh +++ b/program/hypfront/install.sh @@ -1,3 +1,6 @@ -sudo rm -v /var/www/py/* -sudo cp -v --preserve ./*.{xml,py,html,js} /var/www/py/ +sudo rm -rv /var/www/py/* +sudo cp -v ./*.{xml,py,html,js} /var/www/py/ #sudo chown -vR www-data:www-data /var/www/py +sudo mkdir /var/www/py/files +sudo chown -R mart:www-data /var/www/py +sudo chmod -R 770 /var/www/py diff --git a/program/sites.txt b/program/sites.txt new file mode 100644 index 0000000..03236ff --- /dev/null +++ b/program/sites.txt @@ -0,0 +1,15 @@ +www.ziggodome.nl +www.hmh.nl +http://rodahal.nl +www.013.nl +www.paradiso.nl +www.melkweg.nl +www.doornroosje.nl +http://tivoli.nl +www.delamar.nl +https://www.stadsschouwburgendevereeniging.nl +www.dedoelen.nl/ +www.luxorlive.nl +http://www.parktheater.nl +http://www.de-oosterpoort.nl +http://www.chasse.nl -- 2.20.1