From 8d51adcc05c26630f63447787d3d0ace9ff9770d Mon Sep 17 00:00:00 2001 From: James Valleroy Date: Sun, 15 Dec 2019 08:17:46 -0500 Subject: [PATCH] cockpit: Filter out localhost URLs from displayed access list Signed-off-by: James Valleroy --- plinth/modules/cockpit/views.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/plinth/modules/cockpit/views.py b/plinth/modules/cockpit/views.py index a7e7b0d2e..98fa8e4dd 100644 --- a/plinth/modules/cockpit/views.py +++ b/plinth/modules/cockpit/views.py @@ -41,6 +41,7 @@ class CockpitAppView(AppView): def get_context_data(self, *args, **kwargs): context = super().get_context_data(**kwargs) - context['urls'] = get_origin_domains(load_augeas()) + urls = get_origin_domains(load_augeas()) + context['urls'] = [url for url in urls if 'localhost' not in url] return context