modified architecture

This commit is contained in:
2026-01-28 12:07:17 +01:00
parent 36cea198e4
commit 6f0a29a9ea
5 changed files with 6 additions and 10 deletions

View File

@@ -28,19 +28,16 @@ def main() -> None:
signal.signal(signal.SIGTERM, _handle_exit)
signal.signal(signal.SIGINT, _handle_exit)
host = _get_environment_variable("HOST")
port = _get_environment_variable("PORT")
cache_duration = _get_environment_variable("CACHE_DURATION")
ics_url = _get_environment_variable("ICS_URL")
time_zone = _get_environment_variable("TIME_ZONE")
port_int = _parse_environment_variable("PORT", port)
cache_duration_int = _parse_environment_variable("CACHE_DURATION", cache_duration)
utils.set_time_zone(time_zone)
server = Server(host, port_int, cache_duration_int, ics_url)
server = Server("0.0.0.0", 80, cache_duration_int, ics_url)
server.serve()
if __name__ == "__main__":
main()
main()