Adjust routes for reverse proxying
This commit is contained in:
parent
c7e4b8e1ef
commit
24a02f6faf
|
@ -22,7 +22,7 @@ dungeon = dungeon.Dungeon("dungeon")
|
||||||
itemsources = core.load_all_sources("sources")
|
itemsources = core.load_all_sources("sources")
|
||||||
|
|
||||||
|
|
||||||
@app.route("/feed/")
|
@app.route("/")
|
||||||
def root():
|
def root():
|
||||||
active_items = dungeon.get_active_items()
|
active_items = dungeon.get_active_items()
|
||||||
logger.info("Found {} active items".format(len(active_items)))
|
logger.info("Found {} active items".format(len(active_items)))
|
||||||
|
@ -40,8 +40,3 @@ def deactivate():
|
||||||
item = dungeon.deactivate_item(params['source'], params['itemid'])
|
item = dungeon.deactivate_item(params['source'], params['itemid'])
|
||||||
return jsonify({'active': item['active']})
|
return jsonify({'active': item['active']})
|
||||||
|
|
||||||
|
|
||||||
@app.route("/feed.css")
|
|
||||||
def css():
|
|
||||||
with open("feed.css") as f:
|
|
||||||
return f.read()
|
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
<html>
|
<html>
|
||||||
<head>
|
<head>
|
||||||
<link rel="stylesheet" type="text/css" href="/feed.css" />
|
<link rel="stylesheet" type="text/css" href="../feed.css" />
|
||||||
<script>
|
<script>
|
||||||
var deactivate = function (source, itemid) {
|
var deactivate = function (source, itemid) {
|
||||||
fetch('/deactivate/', {
|
fetch('deactivate/', {
|
||||||
method: 'POST',
|
method: 'POST',
|
||||||
headers: {
|
headers: {
|
||||||
'Content-Type': 'application/json; charset=UTF-8',
|
'Content-Type': 'application/json; charset=UTF-8',
|
||||||
|
|
Loading…
Reference in New Issue