Fix: caddy widget broken in 0.9.1 (#3579)

pull/3587/head
shamoon 6 months ago committed by GitHub
parent 9a20982406
commit ccc27142ef
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -8,7 +8,7 @@ export default function Component({ service }) {
const { t } = useTranslation();
const { widget } = service;
const { data: resultData, error: resultError } = useWidgetAPI(widget, "result");
const { data: resultData, error: resultError } = useWidgetAPI(widget, "upstreams");
if (resultError) {
return <Container service={service} error={resultError} />;

@ -1,8 +1,14 @@
import genericProxyHandler from "utils/proxy/handlers/generic";
const widget = {
api: "{url}/reverse_proxy/upstreams",
api: "{url}/{endpoint}",
proxyHandler: genericProxyHandler,
mappings: {
upstreams: {
endpoint: "reverse_proxy/upstreams",
},
},
};
export default widget;

Loading…
Cancel
Save