#pragma once #include #include #include #include "blankie/murl.h" struct IPConnection { std::string address; int port; }; struct UnixConnection { std::string unix; }; struct RedisConfig { std::variant connection_method; std::optional username; std::optional password; }; struct Config { std::string bind_host = "127.0.0.1"; int bind_port = 8080; blankie::murl::Url image_proxy_url{"https://i.pixiv.cat"}; std::optional canonical_origin; std::optional redis_config; }; Config load_config(const char* path); void from_json(const nlohmann::json& j, Config& config);