mirror of
https://github.com/freedombox/FreedomBox.git
synced 2026-04-15 09:51:21 +00:00
Merge branch 'text-updates'
This commit is contained in:
commit
863a187b23
@ -13,9 +13,9 @@ personal servers running free software for private, personal
|
||||
communications. It is a networking appliance designed to allow
|
||||
interfacing with the rest of the Internet under conditions of
|
||||
protected privacy and data security. It hosts applications such as
|
||||
blog, wiki, website, social network, email, web proxy and a Tor relay
|
||||
on a device that can replace your Wi-Fi router so that your data stays
|
||||
with you.
|
||||
blog, wiki, website, social network, email, web proxy and a Tor relay,
|
||||
on a device that can replace your Wi-Fi router, so that your data
|
||||
stays with you.
|
||||
|
||||
Plinth is a web interface to administer the functions of the
|
||||
FreedomBox. It is extensible and provides various applications of
|
||||
|
||||
@ -19,6 +19,7 @@
|
||||
Django context processors to provide common data to templates.
|
||||
"""
|
||||
|
||||
from django.utils.translation import ugettext as _, ugettext_noop
|
||||
import re
|
||||
|
||||
from plinth import cfg
|
||||
@ -30,10 +31,15 @@ def common(request):
|
||||
Any resources referenced in the return value are expected to have been
|
||||
initialized or configured externally beforehand.
|
||||
"""
|
||||
# Allow a value in configuration file to be translated. Allow
|
||||
# the brand name 'FreedomBox' itself to be translated.
|
||||
ugettext_noop('FreedomBox')
|
||||
|
||||
slash_indices = [match.start() for match in re.finditer('/', request.path)]
|
||||
active_menu_urls = [request.path[:index + 1] for index in slash_indices]
|
||||
return {
|
||||
'cfg': cfg,
|
||||
'submenu': cfg.main_menu.active_item(request),
|
||||
'active_menu_urls': active_menu_urls
|
||||
'active_menu_urls': active_menu_urls,
|
||||
'box_name': _(cfg.box_name)
|
||||
}
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -25,7 +25,7 @@
|
||||
<h2>{% trans "Services and Applications" %}</h2>
|
||||
|
||||
<p>
|
||||
{% blocktrans trimmed with box_name=cfg.box_name %}
|
||||
{% blocktrans trimmed %}
|
||||
You can install and run various services and applications on
|
||||
your {{ box_name }}. Click on any app page link on the left to
|
||||
read a description of the application and choose to install it.
|
||||
|
||||
@ -27,11 +27,11 @@
|
||||
|
||||
<p>
|
||||
{% blocktrans trimmed %}
|
||||
Service discovery allows other machines on the network to
|
||||
discover your FreedomBox and services running on it. It also
|
||||
allows FreedomBox to discover other machines and services
|
||||
running on your local network. Service discovery is not
|
||||
essential and works only on internal networks. It may be
|
||||
Service discovery allows other devices on the network to
|
||||
discover your {{ box_name }} and services running on it. It
|
||||
also allows {{ box_name }} to discover other devices and
|
||||
services running on your local network. Service discovery is
|
||||
not essential and works only on internal networks. It may be
|
||||
disabled to improve security especially when connecting to a
|
||||
hostile local network.
|
||||
{% endblocktrans %}
|
||||
|
||||
@ -38,6 +38,7 @@ from plinth.modules.names import SERVICES
|
||||
from plinth.signals import pre_hostname_change, post_hostname_change
|
||||
from plinth.signals import domainname_change
|
||||
from plinth.signals import domain_added, domain_removed
|
||||
from plinth.utils import format_lazy
|
||||
|
||||
|
||||
HOSTNAME_REGEX = r'^[a-zA-Z0-9]([-a-zA-Z0-9]{,61}[a-zA-Z0-9])?$'
|
||||
@ -92,12 +93,12 @@ class ConfigurationForm(forms.Form):
|
||||
# https://tools.ietf.org/html/rfc2181#section-11
|
||||
hostname = TrimmedCharField(
|
||||
label=ugettext_lazy('Hostname'),
|
||||
help_text=\
|
||||
ugettext_lazy('Hostname is the local name by which other machines on '
|
||||
'the local network reach your machine. It must start '
|
||||
'and end with an alphabet or a digit and have as '
|
||||
'interior characters only alphabets, digits and '
|
||||
'hyphens. Total length must be 63 characters or less.'),
|
||||
help_text=format_lazy(ugettext_lazy(
|
||||
'Hostname is the local name by which other devices on the local '
|
||||
'network can reach your {box_name}. It must start and end with '
|
||||
'an alphabet or a digit and have as interior characters only '
|
||||
'alphabets, digits and hyphens. Total length must be 63 '
|
||||
'characters or less.'), box_name=ugettext_lazy(cfg.box_name)),
|
||||
validators=[
|
||||
validators.RegexValidator(
|
||||
HOSTNAME_REGEX,
|
||||
@ -105,14 +106,14 @@ class ConfigurationForm(forms.Form):
|
||||
|
||||
domainname = TrimmedCharField(
|
||||
label=ugettext_lazy('Domain Name'),
|
||||
help_text=\
|
||||
ugettext_lazy('Domain name is the global name by which other machines '
|
||||
'on the Internet can reach you. It must consist of '
|
||||
'labels separated by dots. Each label must start and '
|
||||
'end with an alphabet or a digit and have as interior '
|
||||
'characters only alphabets, digits and hyphens. Length '
|
||||
'of each label must be 63 characters or less. Total '
|
||||
'length of domain name must be 253 characters or less.'),
|
||||
help_text=format_lazy(ugettext_lazy(
|
||||
'Domain name is the global name by which other devices on the '
|
||||
'Internet can reach your {box_name}. It must consist of labels '
|
||||
'separated by dots. Each label must start and end with an '
|
||||
'alphabet or a digit and have as interior characters only '
|
||||
'alphabets, digits and hyphens. Length of each label must be 63 '
|
||||
'characters or less. Total length of domain name must be 253 '
|
||||
'characters or less.'), box_name=ugettext_lazy(cfg.box_name)),
|
||||
required=False,
|
||||
validators=[
|
||||
validators.RegexValidator(
|
||||
@ -123,8 +124,7 @@ class ConfigurationForm(forms.Form):
|
||||
language = forms.ChoiceField(
|
||||
label=ugettext_lazy('Language'),
|
||||
help_text=\
|
||||
ugettext_lazy('Language for this FreedomBox web administration '
|
||||
'interface'),
|
||||
ugettext_lazy('Language for this web administration interface'),
|
||||
required=False,
|
||||
choices=settings.LANGUAGES)
|
||||
|
||||
|
||||
@ -26,6 +26,7 @@ import logging
|
||||
from plinth import actions
|
||||
from plinth import cfg
|
||||
from plinth import package
|
||||
from plinth.utils import format_lazy
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
EMPTYSTRING = 'none'
|
||||
@ -78,9 +79,10 @@ class ConfigureForm(forms.Form):
|
||||
help_server = \
|
||||
ugettext_lazy('Please do not enter a URL here (like '
|
||||
'"https://example.com/") but only the hostname of the '
|
||||
'GnuDIP server (like "example.pcom").')
|
||||
help_domain = \
|
||||
ugettext_lazy('The public domain name you want use to reach your box.')
|
||||
'GnuDIP server (like "example.com").')
|
||||
help_domain = format_lazy(
|
||||
ugettext_lazy('The public domain name you want use to reach your '
|
||||
'{box_name}.'), box_name=ugettext_lazy(cfg.box_name))
|
||||
help_disable_ssl = \
|
||||
ugettext_lazy('Use this option if your provider uses self signed '
|
||||
'certificates.')
|
||||
@ -90,13 +92,14 @@ class ConfigureForm(forms.Form):
|
||||
help_secret = \
|
||||
ugettext_lazy('Leave this field empty if you want to keep your '
|
||||
'previous configured password.')
|
||||
help_ip_url = \
|
||||
ugettext_lazy('Optional Value. If your FreedomBox is not connected '
|
||||
help_ip_url = format_lazy(
|
||||
ugettext_lazy('Optional Value. If your {box_name} is not connected '
|
||||
'directly to the Internet (i.e. connected to a NAT '
|
||||
'router) this URL is used to figure out the real '
|
||||
'Internet IP. The URL should simply return the IP where'
|
||||
'the client comes from. Example: '
|
||||
'http://myip.datasystems24.de')
|
||||
'Internet IP. The URL should simply return the IP where '
|
||||
'the client comes from (example: '
|
||||
'http://myip.datasystems24.de).'),
|
||||
box_name=ugettext_lazy(cfg.box_name))
|
||||
help_user = \
|
||||
ugettext_lazy('You should have been requested to select a username '
|
||||
'when you created the account.')
|
||||
@ -129,11 +132,11 @@ class ConfigureForm(forms.Form):
|
||||
help_text=help_update_url)
|
||||
|
||||
disable_SSL_cert_check = forms.BooleanField(
|
||||
label=ugettext_lazy('accept all SSL certificates'),
|
||||
label=ugettext_lazy('Accept all SSL certificates'),
|
||||
help_text=help_disable_ssl, required=False)
|
||||
|
||||
use_http_basic_auth = forms.BooleanField(
|
||||
label=ugettext_lazy('use HTTP basic authentication'),
|
||||
label=ugettext_lazy('Use HTTP basic authentication'),
|
||||
help_text=help_http_auth, required=False)
|
||||
|
||||
dynamicdns_domain = TrimmedCharField(
|
||||
@ -151,7 +154,7 @@ class ConfigureForm(forms.Form):
|
||||
label=ugettext_lazy('Password'), widget=forms.PasswordInput(),
|
||||
required=False, help_text=help_secret)
|
||||
|
||||
showpw = forms.BooleanField(label=ugettext_lazy('show password'),
|
||||
showpw = forms.BooleanField(label=ugettext_lazy('Show password'),
|
||||
required=False)
|
||||
|
||||
dynamicdns_ipurl = TrimmedCharField(
|
||||
|
||||
@ -22,14 +22,14 @@
|
||||
|
||||
{% block content %}
|
||||
|
||||
<h2>{% trans "DynamicDNS client" %}</h2>
|
||||
<h2>{% trans "Dynamic DNS Client" %}</h2>
|
||||
|
||||
<p>
|
||||
{% blocktrans trimmed %}
|
||||
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).
|
||||
provided by {{ box_name }}, such as ownCloud.
|
||||
{% endblocktrans %}
|
||||
</p>
|
||||
|
||||
@ -41,7 +41,7 @@
|
||||
public IP address to an
|
||||
<a href='http://gnudip2.sourceforge.net/' target='_blank'> gnudip </a>
|
||||
server. Afterwards the Server will assign your DNS name with the
|
||||
new IP and if someone from the internet asks for your DNS name
|
||||
new IP and if someone from the Internet asks for your DNS name
|
||||
he will get your current IP answered.
|
||||
{% endblocktrans %}
|
||||
</p>
|
||||
@ -59,9 +59,9 @@
|
||||
|
||||
<p>
|
||||
{% blocktrans trimmed %}
|
||||
If your freedombox is connected behind some NAT router, don't forget
|
||||
to add portforwarding (i.e. forward some standard ports like 80 and 443)
|
||||
to your freedombox device.
|
||||
If your {{ box_name }} is connected behind some NAT router, don't forget
|
||||
to add port forwarding (i.e. forward some standard ports like 80 and
|
||||
443).
|
||||
{% endblocktrans %}
|
||||
</p>
|
||||
{% endblock %}
|
||||
|
||||
@ -32,14 +32,14 @@
|
||||
{% endblocktrans %}
|
||||
{% else %}
|
||||
{% if no_nat %}
|
||||
{% trans "Direct connection to the internet." %}
|
||||
{% trans "Direct connection to the Internet." %}
|
||||
{% else %}
|
||||
{% blocktrans trimmed %}
|
||||
Behind NAT, this means that dynamic DNS service will poll
|
||||
the "IP check URL" for changes (we need the "IP check URL"
|
||||
for this reason - otherwise we will not detect IP changes).
|
||||
It may take up to {{ timer }} minutes until we update your
|
||||
DNS entry in case of WAN IP change.
|
||||
Behind NAT. This means that Dynamic DNS service will poll
|
||||
the "IP check URL" for changes (the "IP check URL" entry is
|
||||
needed for this - otherwise IP changes will not be
|
||||
detected). In case the WAN IP changes, it may take up to
|
||||
{{ timer }} minutes until your DNS entry is updated.
|
||||
{% endblocktrans %}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
|
||||
@ -25,20 +25,20 @@
|
||||
<h2>{{ title }}</h2>
|
||||
|
||||
<p>
|
||||
{% blocktrans trimmed with box_name=cfg.box_name %}
|
||||
Firewall is a network security system that controls the incoming
|
||||
and outgoing network traffic on your {{ box_name }}. Keeping a
|
||||
{% blocktrans trimmed %}
|
||||
Firewall is a security system that controls the incoming and
|
||||
outgoing network traffic on your {{ box_name }}. Keeping a
|
||||
firewall enabled and properly configured reduces risk of
|
||||
security threat from the Internet.
|
||||
{% endblocktrans %}
|
||||
</p>
|
||||
|
||||
<p>{% trans "The following is the current status:" %}</p>
|
||||
<p>{% trans "Current status:" %}</p>
|
||||
|
||||
{% if firewall_status == 'not_running' %}
|
||||
|
||||
<p>
|
||||
{% blocktrans trimmed with box_name=cfg.box_name %}
|
||||
{% blocktrans trimmed %}
|
||||
Firewall daemon is not running. Please run it. Firewall comes
|
||||
enabled by default on {{ box_name }}. On any Debian based
|
||||
system (such as {{ box_name }}) you may run it using the
|
||||
@ -102,8 +102,8 @@
|
||||
<em>
|
||||
{% blocktrans trimmed %}
|
||||
The operation of the firewall is automatic. When you enable
|
||||
a service it is automatically permitted in the firewall and
|
||||
you disable a service is automatically disabled in the firewall.
|
||||
a service it is also permitted in the firewall and when you
|
||||
disable a service it is also disabled in the firewall.
|
||||
{% endblocktrans %}
|
||||
</em>
|
||||
</p>
|
||||
|
||||
@ -37,7 +37,7 @@
|
||||
{% block content_row %}
|
||||
<p class="text-center">
|
||||
<img src="{% static 'theme/img/FreedomBox-logo-standard.png' %}"
|
||||
alt="{{ cfg.box_name }}" width="640"/>
|
||||
alt="{{ box_name }}" width="640"/>
|
||||
</p>
|
||||
|
||||
<p class="text-center">
|
||||
@ -46,7 +46,7 @@
|
||||
</p>
|
||||
|
||||
<p class="text-center" style="font-size: larger">
|
||||
{% blocktrans trimmed with box_name=cfg.box_name %}
|
||||
{% blocktrans trimmed %}
|
||||
To complete the setup of your {{ box_name }}, please provide
|
||||
some basic information.
|
||||
{% endblocktrans %}
|
||||
|
||||
@ -29,10 +29,10 @@
|
||||
<h2>{% trans "Setup Complete!" %}</h2>
|
||||
|
||||
<p>
|
||||
{% blocktrans trimmed with box_name=cfg.box_name %}
|
||||
{% blocktrans trimmed %}
|
||||
{{ box_name }} setup is now complete. To make your {{ box_name }}
|
||||
functional, you need some applications. Applications will be
|
||||
installed the first time you access them.
|
||||
functional, you need some applications. They will be installed
|
||||
the first time you access them.
|
||||
{% endblocktrans %}
|
||||
</p>
|
||||
|
||||
|
||||
@ -35,7 +35,7 @@ def init():
|
||||
'glyphicon-book', 'help:index', 101)
|
||||
menu.add_urlname(ugettext_lazy('Where to Get Help'), 'glyphicon-search',
|
||||
'help:index_explicit', 5)
|
||||
menu.add_urlname(ugettext_lazy('FreedomBox Manual'), 'glyphicon-info-sign',
|
||||
menu.add_urlname(ugettext_lazy('Manual'), 'glyphicon-info-sign',
|
||||
'help:manual', 10)
|
||||
menu.add_urlname(ugettext_lazy('About'), 'glyphicon-star', 'help:about',
|
||||
100)
|
||||
@ -52,7 +52,7 @@ def index(request):
|
||||
def about(request):
|
||||
"""Serve the about page"""
|
||||
context = {
|
||||
'title': _('About {box_name}').format(box_name=cfg.box_name),
|
||||
'title': _('About {box_name}').format(box_name=_(cfg.box_name)),
|
||||
'version': __version__
|
||||
}
|
||||
return TemplateResponse(request, 'help_about.html', context)
|
||||
@ -68,6 +68,7 @@ def manual(request):
|
||||
except IOError:
|
||||
raise Http404
|
||||
|
||||
return TemplateResponse(request, 'help_manual.html',
|
||||
{'title': _('FreedomBox Manual'),
|
||||
'content': content})
|
||||
return TemplateResponse(
|
||||
request, 'help_manual.html',
|
||||
{'title': _('{box_name} Manual').format(box_name=_(cfg.box_name)),
|
||||
'content': content})
|
||||
|
||||
@ -28,14 +28,14 @@
|
||||
|
||||
<p>
|
||||
{% blocktrans trimmed %}
|
||||
FreedomBox is a community project to develop, design and promote
|
||||
personal servers running free software for private, personal
|
||||
communications. It is a networking appliance designed to allow
|
||||
interfacing with the rest of the Internet under conditions of
|
||||
protected privacy and data security. It hosts applications such
|
||||
as blog, wiki, website, social network, email, web proxy and a
|
||||
Tor relay on a device that can replace your Wi-Fi router so that
|
||||
your data stays with you.
|
||||
{{ box_name }} is a community project to develop, design and
|
||||
promote personal servers running free software for private,
|
||||
personal communications. It is a networking appliance designed
|
||||
to allow interfacing with the rest of the Internet under
|
||||
conditions of protected privacy and data security. It hosts
|
||||
applications such as blog, wiki, website, social network, email,
|
||||
web proxy and a Tor relay, on a device that can replace your
|
||||
Wi-Fi router, so that your data stays with you.
|
||||
{% endblocktrans %}
|
||||
</p>
|
||||
|
||||
@ -55,15 +55,16 @@
|
||||
<p>
|
||||
{% blocktrans trimmed %}
|
||||
There are a number of projects working to realize a future of
|
||||
distributed services; FreedomBox aims to bring them all together
|
||||
in a convenient package.
|
||||
distributed services; {{ box_name }} aims to bring them all
|
||||
together in a convenient package.
|
||||
{% endblocktrans %}
|
||||
</p>
|
||||
|
||||
<p>
|
||||
{% blocktrans trimmed %}
|
||||
For more information about the FreedomBox project, see the
|
||||
<a href="https://wiki.debian.org/FreedomBox">FreedomBox Wiki</a>.
|
||||
For more information about the {{ box_name }} project, see the
|
||||
<a href="https://wiki.debian.org/FreedomBox">{{ box_name }}
|
||||
Wiki</a>.
|
||||
{% endblocktrans %}
|
||||
</p>
|
||||
|
||||
|
||||
@ -33,9 +33,7 @@
|
||||
<img src="{% static 'theme/img/freedombox-logo-32px.png' %}"
|
||||
alt="{{ cfg.box_name }}" />
|
||||
<a href="{% url 'index' %}">
|
||||
{% blocktrans trimmed with box_name=cfg.box_name %}
|
||||
{{ box_name }} Setup
|
||||
{% endblocktrans %}
|
||||
{% blocktrans trimmed %}{{ box_name }} Setup{% endblocktrans %}
|
||||
</a>
|
||||
</span>
|
||||
|
||||
|
||||
@ -26,8 +26,8 @@
|
||||
|
||||
<p>
|
||||
{% url 'help:manual' as manual_url %}
|
||||
{% blocktrans trimmed with box_name=cfg.box_name %}
|
||||
The <a href="{{ manual_url }}">FreedomBox Manual</a> is the
|
||||
{% blocktrans trimmed %}
|
||||
The <a href="{{ manual_url }}">{{ box_name }} Manual</a> is the
|
||||
best place to start for information regarding {{ box_name }}.
|
||||
{% endblocktrans %}
|
||||
</p>
|
||||
@ -35,13 +35,13 @@
|
||||
<p>
|
||||
{% blocktrans trimmed %}
|
||||
<a href="http://wiki.debian.org/FreedomBox" target="_blank">
|
||||
FreedomBox project wiki </a> contains further information.
|
||||
{{ box_name }} project wiki </a> contains further information.
|
||||
{% endblocktrans %}
|
||||
</p>
|
||||
|
||||
<p>
|
||||
{% blocktrans trimmed %}
|
||||
To seek help from FreedomBox community, queries may be posted on
|
||||
To seek help from {{ box_name }} community, queries may be posted on
|
||||
the
|
||||
<a href="https://lists.alioth.debian.org/mailman/listinfo/freedombox-discuss">
|
||||
mailing list</a>. The list archives also contain information
|
||||
@ -51,8 +51,8 @@
|
||||
|
||||
<p>
|
||||
{% blocktrans trimmed %}
|
||||
Many FreedomBox contributors and users are also available on the irc.oftc.net IRC network.
|
||||
Join and request help on the
|
||||
Many {{ box_name }} contributors and users are also available on
|
||||
the irc.oftc.net IRC network. Join and request help on the
|
||||
<a href="https://webchat.oftc.net/?randomnick=1&channels=freedombox&prompt=1">
|
||||
#freedombox</a> channel using the IRC web interface.
|
||||
{% endblocktrans %}
|
||||
|
||||
@ -35,12 +35,12 @@ service = None
|
||||
def init():
|
||||
"""Initialize the ikiwiki module."""
|
||||
menu = cfg.main_menu.get('apps:index')
|
||||
menu.add_urlname(_('Wiki & Blog (Ikiwiki)'), 'glyphicon-edit',
|
||||
menu.add_urlname(_('Wiki and Blog (ikiwiki)'), 'glyphicon-edit',
|
||||
'ikiwiki:index', 1100)
|
||||
|
||||
global service
|
||||
service = service_module.Service(
|
||||
'ikiwiki', _('Ikiwiki wikis and blogs'), ['http', 'https'],
|
||||
'ikiwiki', _('ikiwiki wikis and blogs'), ['http', 'https'],
|
||||
is_external=True, enabled=is_enabled())
|
||||
|
||||
|
||||
|
||||
@ -26,7 +26,7 @@ from django.utils.translation import ugettext_lazy as _
|
||||
class IkiwikiForm(forms.Form):
|
||||
"""ikiwiki configuration form."""
|
||||
enabled = forms.BooleanField(
|
||||
label=_('Enable Ikiwiki'),
|
||||
label=_('Enable ikiwiki'),
|
||||
required=False)
|
||||
|
||||
|
||||
|
||||
@ -25,14 +25,15 @@
|
||||
|
||||
<h3>
|
||||
{% blocktrans trimmed %}
|
||||
Delete Wiki/Blog <em>{{ name }}</em>
|
||||
Delete Wiki or Blog <em>{{ name }}</em>
|
||||
{% endblocktrans %}
|
||||
</h3>
|
||||
|
||||
<p>
|
||||
{% blocktrans trimmed %}
|
||||
This action will remove all the posts, pages and comments
|
||||
including revision history. Delete this wiki/blog permanently?
|
||||
including revision history. Delete this wiki or blog
|
||||
permanently?
|
||||
{% endblocktrans %}
|
||||
</p>
|
||||
|
||||
|
||||
@ -41,7 +41,7 @@ subsubmenu = [{'url': reverse_lazy('ikiwiki:index'),
|
||||
|
||||
|
||||
def on_install():
|
||||
"""Enable Ikiwiki on install."""
|
||||
"""Enable ikiwiki on install."""
|
||||
actions.superuser_run('ikiwiki', ['setup'])
|
||||
ikiwiki.service.notify_enabled(None, True)
|
||||
|
||||
@ -70,7 +70,7 @@ def index(request):
|
||||
form = IkiwikiForm(initial=status, prefix='ikiwiki')
|
||||
|
||||
return TemplateResponse(request, 'ikiwiki.html',
|
||||
{'title': _('Wiki & Blog'),
|
||||
{'title': _('Wiki and Blog'),
|
||||
'status': status,
|
||||
'form': form,
|
||||
'subsubmenu': subsubmenu})
|
||||
@ -129,7 +129,7 @@ def create(request):
|
||||
form = IkiwikiCreateForm(prefix='ikiwiki')
|
||||
|
||||
return TemplateResponse(request, 'ikiwiki_create.html',
|
||||
{'title': _('Create Wiki/Blog'),
|
||||
{'title': _('Create Wiki or Blog'),
|
||||
'form': form,
|
||||
'subsubmenu': subsubmenu})
|
||||
|
||||
@ -179,6 +179,6 @@ def delete(request, name):
|
||||
return redirect(reverse_lazy('ikiwiki:manage'))
|
||||
|
||||
return TemplateResponse(request, 'ikiwiki_delete.html',
|
||||
{'title': _('Delete Wiki/Blog'),
|
||||
{'title': _('Delete Wiki or Blog'),
|
||||
'subsubmenu': subsubmenu,
|
||||
'name': name})
|
||||
|
||||
@ -38,7 +38,7 @@
|
||||
<h2>{% trans "Certificates (Let's Encrypt)" %}</h2>
|
||||
|
||||
<p>
|
||||
{% blocktrans trimmed with box_name=cfg.box_name %}
|
||||
{% blocktrans trimmed %}
|
||||
A digital certficate allows users of a web service to verify the
|
||||
identity of the service and to securely communicate with it.
|
||||
{{ box_name }} can automatically obtain and setup digital
|
||||
|
||||
@ -317,10 +317,10 @@
|
||||
<div class="alert alert-danger">
|
||||
<span class="glyphicon glyphicon-exclamation-sign" aria-hidden="true"></span>
|
||||
{% blocktrans trimmed %}
|
||||
This interface is not maintained by FreedomBox. Its
|
||||
security status is unknown to FreedomBox. Many FreedomBox
|
||||
This interface is not maintained by {{ box_name }}. Its
|
||||
security status is unknown to {{ box_name }}. Many {{ box_name }}
|
||||
services may not be available on this interface. It is
|
||||
recommended that you deactivate/delete this connection and
|
||||
recommended that you deactivate or delete this connection and
|
||||
re-configure it.
|
||||
{% endblocktrans %}
|
||||
</div>
|
||||
|
||||
@ -94,7 +94,7 @@
|
||||
</div>
|
||||
<div class="col-sm-2">
|
||||
<img src="{% static 'theme/img/network-freedombox.svg' %}"
|
||||
class="col-image network-entity" alt="{{ cfg.box_name }}"/>
|
||||
class="col-image network-entity" alt="{{ box_name }}"/>
|
||||
</div>
|
||||
<div class="col-sm-3">
|
||||
<img src="{% static 'theme/img/network-spacing.svg' %}"
|
||||
|
||||
@ -35,9 +35,9 @@
|
||||
<h2>{% trans "Virtual Private Network (OpenVPN)" %}</h2>
|
||||
|
||||
<p>
|
||||
{% blocktrans trimmed with box_name=cfg.box_name %}
|
||||
{% blocktrans trimmed %}
|
||||
Virtual Private Network (VPN) is a technique for securely
|
||||
connecting two machines in order to access resources of a
|
||||
connecting two devices in order to access resources of a
|
||||
private network. While you are away from home, you can connect
|
||||
to your {{ box_name }} in order to join your home network and
|
||||
access private/internal services provided by {{ box_name }}.
|
||||
@ -51,19 +51,19 @@
|
||||
<h3>{% trans "Profile" %}</h3>
|
||||
|
||||
<p>
|
||||
{% blocktrans trimmed with box_name=cfg.box_name %}
|
||||
{% blocktrans trimmed %}
|
||||
To connect to {{ box_name }}'s VPN, you need to download a
|
||||
profile and feed it to an OpenVPN client on your mobile or
|
||||
desktop machine. OpenVPN Clients are available for most
|
||||
platforms. See
|
||||
<a href="https://wiki.debian.org/FreedomBox/Manual/OpenVPN"
|
||||
title="FreedomBox Manual - OpenVPN">documentation</a> on
|
||||
title="{{ box_name }} Manual - OpenVPN">documentation</a> on
|
||||
recommended clients and instructions on how to configure them.
|
||||
{% endblocktrans %}
|
||||
</p>
|
||||
|
||||
<p>
|
||||
{% blocktrans trimmed with box_name=cfg.box_name %}
|
||||
{% blocktrans trimmed %}
|
||||
Profile is specific to each user of {{ box_name }}. Keep it a
|
||||
secret.
|
||||
{% endblocktrans %}
|
||||
@ -82,7 +82,7 @@
|
||||
|
||||
{% if not status.is_setup and not status.setup_running %}
|
||||
<p>
|
||||
{% blocktrans trimmed with box_name=cfg.box_name %}
|
||||
{% blocktrans trimmed %}
|
||||
OpenVPN has not yet been setup. Performing a secure setup
|
||||
takes a very long time. Depending on how fast your
|
||||
{{ box_name }} is, it may even take hours. If the setup
|
||||
@ -105,7 +105,7 @@
|
||||
</p>
|
||||
|
||||
<p>
|
||||
{% blocktrans trimmed with box_name=cfg.box_name %}
|
||||
{% blocktrans trimmed %}
|
||||
To perform a secure setup, this process takes a very long
|
||||
time. Depending on how fast your {{ box_name }} is, it may
|
||||
even take hours. If the setup is interrupted, you may start
|
||||
|
||||
@ -23,7 +23,7 @@
|
||||
{% block content %}
|
||||
|
||||
<p>
|
||||
{% blocktrans trimmed with box_name=cfg.box_name %}
|
||||
{% blocktrans trimmed %}
|
||||
PageKite is a system for exposing {{ box_name }} services when
|
||||
you don't have a direct connection to the Internet. You only
|
||||
need this if your {{ box_name }} services are unreachable from
|
||||
@ -34,13 +34,13 @@
|
||||
|
||||
<ul>
|
||||
<li>
|
||||
{% blocktrans trimmed with box_name=cfg.box_name %}
|
||||
{% blocktrans trimmed %}
|
||||
{{ box_name }} is behind a restricted firewall.
|
||||
{% endblocktrans %}
|
||||
</li>
|
||||
|
||||
<li>
|
||||
{% blocktrans trimmed with box_name=cfg.box_name %}
|
||||
{% blocktrans trimmed %}
|
||||
{{ box_name }} is connected to a (wireless) router which you
|
||||
don't control.
|
||||
{% endblocktrans %}
|
||||
@ -64,7 +64,7 @@
|
||||
</ul>
|
||||
|
||||
<p>
|
||||
{% blocktrans trimmed with box_name=cfg.box_name %}
|
||||
{% blocktrans trimmed %}
|
||||
PageKite works around NAT, firewalls and IP-address limitations
|
||||
by using a combination of tunnels and reverse proxies. You can
|
||||
use any pagekite service provider, for example
|
||||
|
||||
@ -35,7 +35,7 @@
|
||||
</p>
|
||||
|
||||
<p>
|
||||
{% blocktrans trimmed with box_name=cfg.box_name %}
|
||||
{% blocktrans trimmed %}
|
||||
You can use Privoxy by modifying your browser proxy settings to
|
||||
your {{ box_name }} hostname (or IP address) with port 8118.
|
||||
While using Privoxy, you can see its configuration details and
|
||||
|
||||
@ -26,7 +26,7 @@
|
||||
<h2>{% trans "IRC Client (Quassel)" %}</h2>
|
||||
|
||||
<p>
|
||||
{% blocktrans trimmed with box_name=cfg.box_name %}
|
||||
{% blocktrans trimmed %}
|
||||
Quassel is an IRC application that is split into two parts, a
|
||||
"core" and a "client". This allows the core to remain connected
|
||||
to IRC servers, and to continue receiving messages, even when
|
||||
|
||||
@ -31,7 +31,7 @@
|
||||
web applications. The idea is to uncouple web applications from
|
||||
data. No matter where a web application is served from, the
|
||||
data can be stored on an unhosted storage server of user's
|
||||
choice. With reStore, your {{ cfg.box_name }} becomes your
|
||||
choice. With reStore, your {{ box_name }} becomes your
|
||||
unhosted storage server.
|
||||
{% endblocktrans %}
|
||||
</p>
|
||||
|
||||
@ -25,14 +25,14 @@
|
||||
<h2>{% trans "System Configuration" %}</h2>
|
||||
|
||||
<p>
|
||||
{% blocktrans trimmed with box_name=cfg.box_name %}
|
||||
{% blocktrans trimmed %}
|
||||
Here you can administrate the underlying system of your
|
||||
{{ box_name }}.
|
||||
{% endblocktrans %}
|
||||
</p>
|
||||
|
||||
<p>
|
||||
{% blocktrans trimmed with box_name=cfg.box_name %}
|
||||
{% blocktrans trimmed %}
|
||||
The options affect the {{ box_name }} at its most general level,
|
||||
so be careful!
|
||||
{% endblocktrans %}
|
||||
|
||||
@ -85,7 +85,7 @@
|
||||
<h3>{% trans "Bridge" %}</h3>
|
||||
|
||||
<p>
|
||||
{% blocktrans trimmed with box_name=cfg.box_name %}
|
||||
{% blocktrans trimmed %}
|
||||
Your {{ box_name }} is configured as a Tor bridge with obfsproxy,
|
||||
so it can help circumvent censorship. If your {{ box_name }} is
|
||||
behind a router or firewall, you should make sure the following
|
||||
@ -117,7 +117,7 @@
|
||||
<h3>{% trans "SOCKS" %}</h3>
|
||||
|
||||
<p>
|
||||
{% blocktrans trimmed with box_name=cfg.box_name %}
|
||||
{% blocktrans trimmed %}
|
||||
A Tor SOCKS port is available on your {{ box_name }} on TCP port
|
||||
9050.
|
||||
{% endblocktrans %}
|
||||
|
||||
@ -34,6 +34,7 @@ from plinth import package
|
||||
from plinth.errors import ActionError
|
||||
from plinth.modules.names import SERVICES
|
||||
from plinth.signals import domain_added, domain_removed
|
||||
from plinth.utils import format_lazy
|
||||
|
||||
APT_SOURCES_URI_PATHS = ('/files/etc/apt/sources.list/*/uri',
|
||||
'/files/etc/apt/sources.list.d/*/*/uri')
|
||||
@ -48,9 +49,10 @@ class TorForm(forms.Form): # pylint: disable=W0232
|
||||
hs_enabled = forms.BooleanField(
|
||||
label=_('Enable Tor Hidden Service'),
|
||||
required=False,
|
||||
help_text=_('A hidden service will allow FreedomBox to provide '
|
||||
'selected services (such as ownCloud or Chat) without '
|
||||
'revealing its location.'))
|
||||
help_text=format_lazy(_(
|
||||
'A hidden service will allow {box_name} to provide selected '
|
||||
'services (such as ownCloud or chat) without revealing its '
|
||||
'location.'), box_name=_(cfg.box_name)))
|
||||
apt_transport_tor_enabled = forms.BooleanField(
|
||||
label=_('Download software packages over Tor'),
|
||||
required=False,
|
||||
|
||||
@ -19,12 +19,12 @@
|
||||
Framework for working with servers and their services.
|
||||
"""
|
||||
|
||||
import collections
|
||||
from django.utils.translation import ugettext_lazy as _
|
||||
|
||||
import collections
|
||||
|
||||
from plinth import cfg
|
||||
from plinth.signals import service_enabled
|
||||
|
||||
from plinth.utils import format_lazy
|
||||
|
||||
services = {}
|
||||
|
||||
@ -75,5 +75,7 @@ def init():
|
||||
is_external=True, enabled=True)
|
||||
Service('ssh', _('Secure Shell (SSH) Server'), ['ssh'], is_external=True,
|
||||
enabled=True)
|
||||
Service('plinth', _('FreedomBox Web Interface (Plinth)'), ['https'],
|
||||
is_external=True, enabled=True)
|
||||
Service('plinth',
|
||||
format_lazy(_('{box_name} Web Interface (Plinth)'),
|
||||
box_name=_(cfg.box_name)),
|
||||
['https'], is_external=True, enabled=True)
|
||||
|
||||
@ -46,10 +46,12 @@
|
||||
<meta name="msnbot" content="noindex, nofollow, noarchive, noodp" />
|
||||
<meta name="slurp" content="noindex, nofollow, noarchive, noodp, noydir" />
|
||||
<meta name="description"
|
||||
content="{% trans "Plinth administrative interface for the FreedomBox" %}" />
|
||||
content="{% blocktrans trimmed %}
|
||||
Plinth administrative interface for the {{ box_name }}
|
||||
{% endblocktrans %}" />
|
||||
{% block title %}
|
||||
<title>
|
||||
{% if title %} {{ title }} {% else %} {% trans "FreedomBox" %} {% endif %}
|
||||
{% if title %} {{ title }} {% else %} {{ box_name }} {% endif %}
|
||||
</title>
|
||||
{% endblock %}
|
||||
|
||||
@ -86,7 +88,7 @@
|
||||
{% block mainmenu_left %}
|
||||
<span class="navbar-brand">
|
||||
<img src="{% static 'theme/img/freedombox-logo-32px.png' %}"
|
||||
alt="{{ cfg.box_name }}" />
|
||||
alt="{{ box_name }}" />
|
||||
</span>
|
||||
<a href="{% url 'index' %}" class="navbar-brand" title="{% trans "Applications" %}">
|
||||
<span class="glyphicon glyphicon-th"></span>
|
||||
|
||||
@ -42,6 +42,8 @@ class ContextProcessorsTestCase(TestCase):
|
||||
self.assertIsNotNone(config)
|
||||
self.assertEqual('FreedomBox', config.box_name)
|
||||
|
||||
self.assertEqual('FreedomBox', response['box_name'])
|
||||
|
||||
submenu = response['submenu']
|
||||
self.assertIsNone(submenu)
|
||||
|
||||
|
||||
@ -20,6 +20,7 @@ Miscelleneous utility method.
|
||||
"""
|
||||
|
||||
import importlib
|
||||
from django.utils.functional import lazy
|
||||
|
||||
|
||||
def import_from_gi(library, version):
|
||||
@ -34,3 +35,12 @@ def import_from_gi(library, version):
|
||||
package.require_version(library, version)
|
||||
|
||||
return importlib.import_module(package_name + '.repository.' + library)
|
||||
|
||||
|
||||
def _format_lazy(string, *args, **kwargs):
|
||||
"""Lazily format a lazy string."""
|
||||
string = str(string)
|
||||
return string.format(*args, **kwargs)
|
||||
|
||||
|
||||
format_lazy = lazy(_format_lazy, str)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user