forked from MarseyWorld/MarseyWorld
master
parent
4155b2ca3b
commit
15aa2bfc0a
|
@ -33,7 +33,7 @@ app.config['SQLALCHEMY_TRACK_MODIFICATIONS'] = False
|
||||||
app.config['DATABASE_URL'] = environ.get("DATABASE_URL", "postgresql://postgres@localhost:5432")
|
app.config['DATABASE_URL'] = environ.get("DATABASE_URL", "postgresql://postgres@localhost:5432")
|
||||||
app.config['SECRET_KEY'] = environ.get('MASTER_KEY')
|
app.config['SECRET_KEY'] = environ.get('MASTER_KEY')
|
||||||
app.config["SERVER_NAME"] = environ.get("DOMAIN").strip()
|
app.config["SERVER_NAME"] = environ.get("DOMAIN").strip()
|
||||||
app.config['SEND_FILE_MAX_AGE_DEFAULT'] = 2628000
|
app.config['SEND_FILE_MAX_AGE_DEFAULT'] = 3153600
|
||||||
app.config["SESSION_COOKIE_NAME"] = "session_" + environ.get("SITE_NAME").strip().lower()
|
app.config["SESSION_COOKIE_NAME"] = "session_" + environ.get("SITE_NAME").strip().lower()
|
||||||
app.config["VERSION"] = "1.0.0"
|
app.config["VERSION"] = "1.0.0"
|
||||||
app.config['MAX_CONTENT_LENGTH'] = 8 * 1024 * 1024
|
app.config['MAX_CONTENT_LENGTH'] = 8 * 1024 * 1024
|
||||||
|
|
|
@ -343,7 +343,7 @@ def static_service(path):
|
||||||
resp = make_response(send_from_directory('assets', path))
|
resp = make_response(send_from_directory('assets', path))
|
||||||
if request.path.endswith('.webp') or request.path.endswith('.gif') or request.path.endswith('.ttf') or request.path.endswith('.woff') or request.path.endswith('.woff2'):
|
if request.path.endswith('.webp') or request.path.endswith('.gif') or request.path.endswith('.ttf') or request.path.endswith('.woff') or request.path.endswith('.woff2'):
|
||||||
resp.headers.remove("Cache-Control")
|
resp.headers.remove("Cache-Control")
|
||||||
resp.headers.add("Cache-Control", "public, max-age=2628000")
|
resp.headers.add("Cache-Control", "public, max-age=3153600")
|
||||||
|
|
||||||
if request.path.endswith('.webp'):
|
if request.path.endswith('.webp'):
|
||||||
resp.headers.remove("Content-Type")
|
resp.headers.remove("Content-Type")
|
||||||
|
@ -358,7 +358,7 @@ def static_service(path):
|
||||||
def images(path):
|
def images(path):
|
||||||
resp = make_response(send_from_directory('/images', path.replace('.WEBP','.webp')))
|
resp = make_response(send_from_directory('/images', path.replace('.WEBP','.webp')))
|
||||||
resp.headers.remove("Cache-Control")
|
resp.headers.remove("Cache-Control")
|
||||||
resp.headers.add("Cache-Control", "public, max-age=2628000")
|
resp.headers.add("Cache-Control", "public, max-age=3153600")
|
||||||
if request.path.endswith('.webp'):
|
if request.path.endswith('.webp'):
|
||||||
resp.headers.remove("Content-Type")
|
resp.headers.remove("Content-Type")
|
||||||
resp.headers.add("Content-Type", "image/webp")
|
resp.headers.add("Content-Type", "image/webp")
|
||||||
|
|
|
@ -420,7 +420,7 @@ def usersong(username):
|
||||||
def song(song):
|
def song(song):
|
||||||
resp = make_response(send_from_directory('/songs', song))
|
resp = make_response(send_from_directory('/songs', song))
|
||||||
resp.headers.remove("Cache-Control")
|
resp.headers.remove("Cache-Control")
|
||||||
resp.headers.add("Cache-Control", "public, max-age=2628000")
|
resp.headers.add("Cache-Control", "public, max-age=3153600")
|
||||||
return resp
|
return resp
|
||||||
|
|
||||||
@app.post("/subscribe/<post_id>")
|
@app.post("/subscribe/<post_id>")
|
||||||
|
|
|
@ -46,16 +46,6 @@
|
||||||
|
|
||||||
<body id="login">
|
<body id="login">
|
||||||
|
|
||||||
<nav class="navbar navbar-expand-lg navbar-dark bg-transparent fixed-top border-0">
|
|
||||||
<div class="container-fluid">
|
|
||||||
<button class="navbar-toggler d-none" role="button" data-bs-toggle="collapse" data-bs-target="#navbarResponsive"
|
|
||||||
aria-controls="navbarResponsive" aria-expanded="false" aria-label="Toggle navigation">
|
|
||||||
<span class="navbar-toggler-icon"></span>
|
|
||||||
</button>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
|
|
||||||
<div class="container-fluid position-absolute h-100 p-0">
|
<div class="container-fluid position-absolute h-100 p-0">
|
||||||
<div class="row no-gutters h-100">
|
<div class="row no-gutters h-100">
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
<meta name="description" content="{{config('DESCRIPTION')}}">
|
<meta name="description" content="{{config('DESCRIPTION')}}">
|
||||||
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline' 'unsafe-eval' ajax.cloudflare.com; connect-src 'self' tls-use1.fpapi.io api.fpjs.io {% if PUSHER_ID != '3435tdfsdudebussylmaoxxt43' %}{{PUSHER_ID}}.pushnotifications.pusher.com{% endif %}; object-src 'none';">
|
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline' 'unsafe-eval' ajax.cloudflare.com; connect-src 'self' tls-use1.fpapi.io api.fpjs.io {% if PUSHER_ID != '3435tdfsdudebussylmaoxxt43' %}{{PUSHER_ID}}.pushnotifications.pusher.com{% endif %}; object-src 'none';">
|
||||||
|
|
||||||
<script src="/static/assets/js/bootstrap.js?a=240"></script>
|
<script src="/static/assets/js/bootstrap.js?a=241"></script>
|
||||||
{% if v %}
|
{% if v %}
|
||||||
<style>:root{--primary:#{{v.themecolor}}}</style>
|
<style>:root{--primary:#{{v.themecolor}}}</style>
|
||||||
<link rel="stylesheet" href="/static/assets/css/main.css?a=141">
|
<link rel="stylesheet" href="/static/assets/css/main.css?a=141">
|
||||||
|
|
|
@ -75,11 +75,6 @@
|
||||||
{% else %}
|
{% else %}
|
||||||
<a class="mobile-nav-icon d-md-none" href="/login"><i class="fas fa-feather-alt align-middle text-gray-500 black"></i></a>
|
<a class="mobile-nav-icon d-md-none" href="/login"><i class="fas fa-feather-alt align-middle text-gray-500 black"></i></a>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
<button class="navbar-toggler" role="button" data-bs-toggle="collapse" data-bs-target="#navbarResponsive"
|
|
||||||
aria-controls="navbarResponsive" aria-expanded="false" aria-label="Toggle navigation">
|
|
||||||
<span class="navbar-toggler-icon {% if v and v.notifications_count %}position-relative{% endif %}"><i class="fal fa-bars text-gray-500 black"></i>
|
|
||||||
</span>
|
|
||||||
</button>
|
|
||||||
<div class="collapse navbar-collapse" id="navbarResponsive">
|
<div class="collapse navbar-collapse" id="navbarResponsive">
|
||||||
<ul class="navbar-nav ml-auto d-none d-md-flex">
|
<ul class="navbar-nav ml-auto d-none d-md-flex">
|
||||||
|
|
||||||
|
|
|
@ -6,7 +6,7 @@
|
||||||
<meta name="description" content="{{config('DESCRIPTION')}}">
|
<meta name="description" content="{{config('DESCRIPTION')}}">
|
||||||
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline'; connect-src 'self'; object-src 'none';">
|
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline'; connect-src 'self'; object-src 'none';">
|
||||||
|
|
||||||
<script src="/static/assets/js/bootstrap.js?a=240"></script>
|
<script src="/static/assets/js/bootstrap.js?a=241"></script>
|
||||||
|
|
||||||
<meta charset="utf-8">
|
<meta charset="utf-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
||||||
|
@ -25,16 +25,6 @@
|
||||||
|
|
||||||
<body id="login">
|
<body id="login">
|
||||||
|
|
||||||
<nav class="navbar navbar-expand-lg navbar-dark bg-transparent fixed-top border-0">
|
|
||||||
<div class="container-fluid">
|
|
||||||
<button class="navbar-toggler d-none" role="button" data-bs-toggle="collapse" data-bs-target="#navbarResponsive"
|
|
||||||
aria-controls="navbarResponsive" aria-expanded="false" aria-label="Toggle navigation">
|
|
||||||
<span class="navbar-toggler-icon"></span>
|
|
||||||
</button>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
|
|
||||||
<div class="container-fluid position-absolute h-100 p-0 overflow-auto">
|
<div class="container-fluid position-absolute h-100 p-0 overflow-auto">
|
||||||
<div class="row no-gutters h-100">
|
<div class="row no-gutters h-100">
|
||||||
|
|
||||||
|
|
|
@ -20,17 +20,6 @@
|
||||||
|
|
||||||
<body id="login">
|
<body id="login">
|
||||||
|
|
||||||
|
|
||||||
<nav class="navbar navbar-expand-lg navbar-dark bg-transparent fixed-top border-0">
|
|
||||||
<div class="container-fluid">
|
|
||||||
<button class="navbar-toggler d-none" role="button" data-bs-toggle="collapse" data-bs-target="#navbarResponsive"
|
|
||||||
aria-controls="navbarResponsive" aria-expanded="false" aria-label="Toggle navigation">
|
|
||||||
<span class="navbar-toggler-icon"></span>
|
|
||||||
</button>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
|
|
||||||
<div class="container-fluid position-absolute h-100 p-0 overflow-auto">
|
<div class="container-fluid position-absolute h-100 p-0 overflow-auto">
|
||||||
<div class="row no-gutters h-100">
|
<div class="row no-gutters h-100">
|
||||||
|
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
<meta name="description" content="{{config('DESCRIPTION')}}">
|
<meta name="description" content="{{config('DESCRIPTION')}}">
|
||||||
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline'; connect-src 'self'; object-src 'none';">
|
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline'; connect-src 'self'; object-src 'none';">
|
||||||
|
|
||||||
<script src="/static/assets/js/bootstrap.js?a=240"></script>
|
<script src="/static/assets/js/bootstrap.js?a=241"></script>
|
||||||
|
|
||||||
<meta charset="utf-8">
|
<meta charset="utf-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
||||||
|
|
|
@ -6,7 +6,7 @@
|
||||||
<meta name="description" content="{{config('DESCRIPTION')}}">
|
<meta name="description" content="{{config('DESCRIPTION')}}">
|
||||||
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline'; connect-src 'self'; object-src 'none';">
|
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline'; connect-src 'self'; object-src 'none';">
|
||||||
|
|
||||||
<script src="/static/assets/js/bootstrap.js?a=240"></script>
|
<script src="/static/assets/js/bootstrap.js?a=241"></script>
|
||||||
|
|
||||||
<meta charset="utf-8">
|
<meta charset="utf-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
<meta name="description" content="{{config('DESCRIPTION')}}">
|
<meta name="description" content="{{config('DESCRIPTION')}}">
|
||||||
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline'; connect-src 'self'; object-src 'none';">
|
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline'; connect-src 'self'; object-src 'none';">
|
||||||
|
|
||||||
<script src="/static/assets/js/bootstrap.js?a=240"></script>
|
<script src="/static/assets/js/bootstrap.js?a=241"></script>
|
||||||
|
|
||||||
<meta charset="utf-8">
|
<meta charset="utf-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
||||||
|
@ -37,16 +37,6 @@
|
||||||
|
|
||||||
<body id="login">
|
<body id="login">
|
||||||
|
|
||||||
<nav class="navbar navbar-expand-lg navbar-dark bg-transparent fixed-top border-0">
|
|
||||||
<div class="container-fluid">
|
|
||||||
<button class="navbar-toggler d-none" role="button" data-bs-toggle="collapse" data-bs-target="#navbarResponsive"
|
|
||||||
aria-controls="navbarResponsive" aria-expanded="false" aria-label="Toggle navigation">
|
|
||||||
<span class="navbar-toggler-icon"></span>
|
|
||||||
</button>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
|
|
||||||
<div class="container-fluid position-absolute h-100 p-0 overflow-auto">
|
<div class="container-fluid position-absolute h-100 p-0 overflow-auto">
|
||||||
<div class="row no-gutters h-100">
|
<div class="row no-gutters h-100">
|
||||||
|
|
||||||
|
|
|
@ -6,7 +6,7 @@
|
||||||
<meta name="description" content="{{config('DESCRIPTION')}}">
|
<meta name="description" content="{{config('DESCRIPTION')}}">
|
||||||
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline'; connect-src 'self'; object-src 'none';">
|
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline'; connect-src 'self'; object-src 'none';">
|
||||||
|
|
||||||
<script src="/static/assets/js/bootstrap.js?a=240"></script>
|
<script src="/static/assets/js/bootstrap.js?a=241"></script>
|
||||||
|
|
||||||
<meta charset="utf-8">
|
<meta charset="utf-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
||||||
|
@ -38,16 +38,6 @@
|
||||||
|
|
||||||
<body id="login">
|
<body id="login">
|
||||||
|
|
||||||
<nav class="navbar navbar-expand-lg navbar-dark bg-transparent fixed-top border-0">
|
|
||||||
<div class="container-fluid">
|
|
||||||
<button class="navbar-toggler d-none" role="button" data-bs-toggle="collapse" data-bs-target="#navbarResponsive"
|
|
||||||
aria-controls="navbarResponsive" aria-expanded="false" aria-label="Toggle navigation">
|
|
||||||
<span class="navbar-toggler-icon"></span>
|
|
||||||
</button>
|
|
||||||
</div>
|
|
||||||
</nav>
|
|
||||||
|
|
||||||
|
|
||||||
<div class="container-fluid position-absolute h-100 p-0">
|
<div class="container-fluid position-absolute h-100 p-0">
|
||||||
<div class="row no-gutters h-100">
|
<div class="row no-gutters h-100">
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
<meta name="description" content="{{config('DESCRIPTION')}}">
|
<meta name="description" content="{{config('DESCRIPTION')}}">
|
||||||
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline'; connect-src 'self'; object-src 'none';">
|
<meta http-equiv="Content-Security-Policy" content="script-src 'self' 'unsafe-inline'; connect-src 'self'; object-src 'none';">
|
||||||
|
|
||||||
<script src="/static/assets/js/bootstrap.js?a=240"></script>
|
<script src="/static/assets/js/bootstrap.js?a=241"></script>
|
||||||
|
|
||||||
<meta charset="utf-8">
|
<meta charset="utf-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
||||||
|
|
Loading…
Reference in New Issue