Merge branch 'develop' of ssh://code.yavook.de:22022/Zaphlebeod/advent22 into develop
This commit is contained in:
commit
337d8d34ff
4 changed files with 20 additions and 0 deletions
|
@ -41,6 +41,14 @@ class RedisSettings(BaseModel):
|
||||||
db: int = 0
|
db: int = 0
|
||||||
protocol: int = 3
|
protocol: int = 3
|
||||||
|
|
||||||
|
@property
|
||||||
|
def url(self) -> str:
|
||||||
|
"""
|
||||||
|
Combined DAV URL.
|
||||||
|
"""
|
||||||
|
|
||||||
|
return f"redis_v{self.protocol}://{self.host}:{self.port}/db_{self.db}"
|
||||||
|
|
||||||
|
|
||||||
class Settings(BaseSettings):
|
class Settings(BaseSettings):
|
||||||
"""
|
"""
|
||||||
|
|
|
@ -48,6 +48,7 @@ class ConfigModel(BaseModel):
|
||||||
puzzle: __Puzzle
|
puzzle: __Puzzle
|
||||||
calendar: __Calendar
|
calendar: __Calendar
|
||||||
image: Image
|
image: Image
|
||||||
|
redis_url: str
|
||||||
webdav: __WebDAV
|
webdav: __WebDAV
|
||||||
|
|
||||||
|
|
||||||
|
@ -82,6 +83,7 @@ async def get_config_model(
|
||||||
"background": cal_cfg.background,
|
"background": cal_cfg.background,
|
||||||
},
|
},
|
||||||
"image": cfg.image,
|
"image": cfg.image,
|
||||||
|
"redis_url": SETTINGS.redis.url,
|
||||||
"webdav": {
|
"webdav": {
|
||||||
"url": SETTINGS.webdav.url,
|
"url": SETTINGS.webdav.url,
|
||||||
"cache_ttl": SETTINGS.webdav.cache_ttl,
|
"cache_ttl": SETTINGS.webdav.cache_ttl,
|
||||||
|
|
|
@ -132,6 +132,14 @@
|
||||||
|
|
||||||
<dt>Konfigurationsdatei</dt>
|
<dt>Konfigurationsdatei</dt>
|
||||||
<dd>{{ config_model.webdav.config_file }}</dd>
|
<dd>{{ config_model.webdav.config_file }}</dd>
|
||||||
|
</dl>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="content">
|
||||||
|
<h3>Sonstige</h3>
|
||||||
|
<dl>
|
||||||
|
<dt>Redis</dt>
|
||||||
|
<dd>{{ config_model.redis_url }}</dd>
|
||||||
|
|
||||||
<dt>UI-Admin</dt>
|
<dt>UI-Admin</dt>
|
||||||
<dd class="is-family-monospace">
|
<dd class="is-family-monospace">
|
||||||
|
@ -191,6 +199,7 @@ export default class extends Vue {
|
||||||
border: 0,
|
border: 0,
|
||||||
fonts: [{ file: "consetetur", size: 0 }],
|
fonts: [{ file: "consetetur", size: 0 }],
|
||||||
},
|
},
|
||||||
|
redis_url: "sadipscing elitr",
|
||||||
webdav: {
|
webdav: {
|
||||||
url: "sadipscing elitr",
|
url: "sadipscing elitr",
|
||||||
cache_ttl: 0,
|
cache_ttl: 0,
|
||||||
|
|
|
@ -21,6 +21,7 @@ export interface ConfigModel {
|
||||||
border: number;
|
border: number;
|
||||||
fonts: { file: string; size: number }[];
|
fonts: { file: string; size: number }[];
|
||||||
};
|
};
|
||||||
|
redis_url: string;
|
||||||
webdav: {
|
webdav: {
|
||||||
url: string;
|
url: string;
|
||||||
cache_ttl: number;
|
cache_ttl: number;
|
||||||
|
|
Loading…
Reference in a new issue