From 3cf36b0e93a3f599203d2d4626a77f264af84f59 Mon Sep 17 00:00:00 2001 From: Chaim Lev-Ari Date: Thu, 30 Nov 2023 07:18:15 +0200 Subject: [PATCH] fix(app/templates): show default url in settings [EE-6393] (#10706) --- .../TemplatesUrlSection.tsx | 36 ++++++++++++------- 1 file changed, 23 insertions(+), 13 deletions(-) diff --git a/app/react/portainer/settings/SettingsView/ApplicationSettingsPanel/TemplatesUrlSection.tsx b/app/react/portainer/settings/SettingsView/ApplicationSettingsPanel/TemplatesUrlSection.tsx index beee1fdf5..b25d25fff 100644 --- a/app/react/portainer/settings/SettingsView/ApplicationSettingsPanel/TemplatesUrlSection.tsx +++ b/app/react/portainer/settings/SettingsView/ApplicationSettingsPanel/TemplatesUrlSection.tsx @@ -4,30 +4,40 @@ import { FormControl } from '@@/form-components/FormControl'; import { FormSection } from '@@/form-components/FormSection'; import { Input } from '@@/form-components/Input'; +// this value is taken from https://github.com/portainer/portainer/blob/develop/api/portainer.go#L1628 +const DEFAULT_URL = + 'https://raw.githubusercontent.com/portainer/templates/v3/templates.json'; + export function TemplatesUrlSection() { const [{ name }, { error }] = useField('templatesUrl'); + return (
- - You can specify the URL to your own template definitions file here. - See{' '} - - Portainer documentation - {' '} - for more details. - +
+

+ You can specify the URL to your own template definitions file here. + See{' '} + + Portainer documentation + {' '} + for more details. +

+

+ The default value is {DEFAULT_URL} +

+