From 70bb2dd9afe266ec2b2579a1dbc10022e165e37c Mon Sep 17 00:00:00 2001 From: nathaniel smith Date: Mon, 5 Sep 2016 10:56:27 +0000 Subject: [PATCH] stuff that was sitting around uncommitted --- tildetown/app.py | 31 ++++++------ tildetown/stats.py | 2 +- tildetown/templates/frontpage.html | 77 ++++++++++++++++++++++++++++-- tildetown/templates/guestbook.html | 2 +- tildetown/templates/helpdesk.html | 2 +- 5 files changed, 92 insertions(+), 22 deletions(-) diff --git a/tildetown/app.py b/tildetown/app.py index f86ec09..a71bc39 100644 --- a/tildetown/app.py +++ b/tildetown/app.py @@ -28,6 +28,20 @@ SITE_NAME = 'tilde.town' app = Flask('~cgi') +app.config['DEBUG'] = True +# tension between this and cfg function... + +conf = ConfigFactory.parse_file('cfg.conf') + +#logfile = conf.get('logfile', '/tmp/cgi.log') +#logging.basicConfig(filename=logfile, level=logging.DEBUG) +logging.basicConfig(filename='/tmp/cgi.log', level=logging.DEBUG) + +app.config['DATA_DIR'] = conf['guestbook_dir'] +app.config['TRELLO_EMAIL'] = conf['trello_email'] +app.config['MAILGUN_URL'] = conf['mailgun_url'] +app.config['MAILGUN_KEY'] = conf['mailgun_key'] + @lru_cache(maxsize=32) def site_context(): return get_data() @@ -56,6 +70,7 @@ def get_random(): @app.route('/guestbook', methods=['GET']) def get_guestbook(): + logging.debug(app.config) logging.debug('loading guestbook') data_dir = app.config['DATA_DIR'] # TODO sort by timestamp @@ -121,20 +136,4 @@ def post_helpdesk(): return redirect('/helpdesk?status={}&desc={}'.format(status, desc)) if __name__ == '__main__': - app.config['DEBUG'] = True - # tension between this and cfg function... - - conf = ConfigFactory.parse_file('cfg.conf') - - logfile = conf.get('logfile', '/tmp/cgi.log') - logging.basicConfig(filename=logfile, level=logging.DEBUG) - - app.config['DATA_DIR'] = conf['guestbook_dir'] - app.config['TRELLO_EMAIL'] = conf['trello_email'] - app.config['MAILGUN_URL'] = conf['mailgun_url'] - app.config['MAILGUN_KEY'] = conf['mailgun_key'] - - logging.debug("Running with data_dir=", app.config['DATA_DIR']) - logging.debug(app.config) - app.run() diff --git a/tildetown/stats.py b/tildetown/stats.py index 2061662..0845c2f 100755 --- a/tildetown/stats.py +++ b/tildetown/stats.py @@ -136,7 +136,7 @@ def tdp(): # TDP format data data = { 'name': 'tilde.town', - 'url': 'http://tilde.town', + 'url': 'https://tilde.town', 'signup_url': 'http://goo.gl/forms/8IvQFTDjlo', 'want_users': True, 'admin_email': 'nks@lambdaphil.es', diff --git a/tildetown/templates/frontpage.html b/tildetown/templates/frontpage.html index 72c5865..e3f3297 100644 --- a/tildetown/templates/frontpage.html +++ b/tildetown/templates/frontpage.html @@ -47,15 +47,15 @@

stuff you can do here

@@ -198,6 +198,77 @@ orators, singers, musicians to come!

news

+

recent outage

+

Thu Aug 11 17:58:00 UTC 2016

+

+ There was recently an issue with AWS that blocked off HTTP, UDP, + and outbound traffic from the town. The outage lasted about 24 + hours and is now resolved. +

+ +

tilde.town in the washington post

+

Mon May 9 21:36:08 UTC 2016

+

+ Our entry on brutalist websites was mentioned on a + + Washington Post blog. Apparently, tilde.town is + both ugly and hard to use ^_^ Let ~vilmibm know if this is the + case... +

+

https support

+

Mon Mar 28 06:25:27 UTC 2016

+

+ Thanks to the gracious help of user + ~demophoon + the town is now accessible over https! just hit up + https://tilde.town + in ye olde browsere to check it out. +

+

irc client fixed for all users

+

Tue Feb 23 16:31:58 PST 2016

+

+ the irc and chat commands are now + fixed for all users. in the course of this fix i accidentally + deleted everyone's weechat config. if you had a bunch of stuff + in your weechat config that you really want back let me know and + i can check the backups. +

+ +

irc client outage

+

Fri Feb 19 13:39:25 PST 2016

+ +

+ because of Reasons, the irc and chat scripts are broken. you can still use irc, you just have to run the following: +

+irc
+/set irc.look.temporary_servers on
+/quit
+irc
+                
+ + and you should be good to go until this is fixed. +

+ +

Restart today

+

Fri Feb 19 12:07:09 PST 2016

+ +

+ Thanks to this + glibc vulnerability the town needs to restart to install + security updates. +

+

+ remember your tilde.town apocalypse training: +

+

+

Systems status

Wed Oct 14 13:49:12 PDT 2015

diff --git a/tildetown/templates/guestbook.html b/tildetown/templates/guestbook.html index e1f9f92..732a23c 100644 --- a/tildetown/templates/guestbook.html +++ b/tildetown/templates/guestbook.html @@ -2,7 +2,7 @@ {{site_name}} guestbook - +

{{site_name}} guestbook

diff --git a/tildetown/templates/helpdesk.html b/tildetown/templates/helpdesk.html index 8740960..91e5850 100644 --- a/tildetown/templates/helpdesk.html +++ b/tildetown/templates/helpdesk.html @@ -2,7 +2,7 @@ {{ site_name }} help desk - +

{{ site_name }} help desk