diff --git a/plinth/modules/dynamicdns/dynamicdns.py b/plinth/modules/dynamicdns/dynamicdns.py index 15d60f95a..a3c80746c 100644 --- a/plinth/modules/dynamicdns/dynamicdns.py +++ b/plinth/modules/dynamicdns/dynamicdns.py @@ -26,6 +26,7 @@ import logging from plinth import actions from plinth import cfg +from plinth import package LOGGER = logging.getLogger(__name__) @@ -45,20 +46,14 @@ def init(): @login_required +@package.required('ez-ipupdate') def index(request): """Serve dynamic DNS page""" - is_installed = actions.run('dynamicdns', ['get-installed']).strip() \ - == 'installed' - - if is_installed: - index_subsubmenu = subsubmenu - else: - index_subsubmenu = None + index_subsubmenu = subsubmenu return TemplateResponse(request, 'dynamicdns.html', {'title': _('dynamicdns'), - 'is_installed': is_installed, 'subsubmenu': index_subsubmenu}) @@ -123,6 +118,7 @@ class ConfigureForm(forms.Form): @login_required +@package.required('ez-ipupdate') def configure(request): """Serve the configuration form""" status = get_status() @@ -144,6 +140,7 @@ def configure(request): @login_required +@package.required('ez-ipupdate') def statuspage(request): """Serve the status page """ check_nat = actions.run('dynamicdns', ['get-nat']) diff --git a/plinth/modules/dynamicdns/templates/dynamicdns.html b/plinth/modules/dynamicdns/templates/dynamicdns.html index 44607d12d..cf6afdb93 100644 --- a/plinth/modules/dynamicdns/templates/dynamicdns.html +++ b/plinth/modules/dynamicdns/templates/dynamicdns.html @@ -21,22 +21,8 @@ {% load bootstrap %} {% block content %} - -{% if is_installed %} - +

DynamicDNS client

If your internet provider changes your IP address periodic (i.e. every 24h) it may be hard for others to find you in the WEB. And for this reason nobody may find the services which are provided by freedombox (like your owncloud). The solution is to assign a DNS name to your IP address and update the DNS name every time your IP is changed by your Internet provider. Dynamic DNS allows you to push your current public IP address to an gnudip server. Afterwards the Server will assign your personal DNS name with the new IP and if someone from the internet asks for your DNS name he will get your personal IP answered.

-{% else %} - -

DynamicDNS client

- -

The Dynamic DNS tool ez-ipupdate is not installed.

- -

ez-ipupdate comes pre-installed with {{ cfg.box_name }}. On any Debian-based - system (such as {{ cfg.box_name }}) you may install it using the command - apt-get install ez-ipupdate.

- -{% endif %} - {% endblock %}