blob: 90011db0d8a61bedd6f93839011cda37aac20eaa [file] [log] [blame]
Sergiusz Bazanskibe897072020-07-25 12:18:59 +02001import jinja2
2import webapp2
3import os
4
5JINJA_ENVIRONMENT = jinja2.Environment(
6 loader=jinja2.FileSystemLoader(os.path.dirname(__file__)),
7 extensions=['jinja2.ext.autoescape'],
8 autoescape=True)
9
10class LandingPage(webapp2.RequestHandler):
11 def get(self):
12 template_values = {}
13 template = JINJA_ENVIRONMENT.get_template('index.html')
14 self.response.write(template.render(template_values))
15
16class Camp19Page(webapp2.RequestHandler):
17 def get(self):
18 self.redirect('https://events.ccc.de/camp/2019/wiki/Village:IXP')
19
20class PricingPage(webapp2.RequestHandler):
21 def get(self):
22 template_values = {}
23 template = JINJA_ENVIRONMENT.get_template('pricing.html')
24 self.response.write(template.render(template_values))
25
26app = webapp2.WSGIApplication([
27 ('/', LandingPage),
28 ('/cccamp19', Camp19Page),
29 ('/ccccamp19', Camp19Page),
30 ('/camp19', Camp19Page),
31 ('/camp', Camp19Page),
32 ('/cccamp', Camp19Page),
33 ('/ccccamp', Camp19Page),
34 ('/pricing', PricingPage),
35 ('/prices', PricingPage),
36 ('/price', PricingPage),
37], debug=False)