mirror of
https://github.com/freedombox/FreedomBox.git
synced 2026-05-20 10:34:30 +00:00
Fix missing import and pass before_install correctly.
This commit is contained in:
parent
ca61649105
commit
eca896a2e8
@ -22,6 +22,7 @@ from django.core.urlresolvers import reverse_lazy
|
|||||||
from django.template.response import TemplateResponse
|
from django.template.response import TemplateResponse
|
||||||
from gettext import gettext as _
|
from gettext import gettext as _
|
||||||
import logging
|
import logging
|
||||||
|
import socket
|
||||||
|
|
||||||
from plinth import actions
|
from plinth import actions
|
||||||
from plinth import cfg
|
from plinth import cfg
|
||||||
@ -65,7 +66,7 @@ def before_install():
|
|||||||
"""Preseed debconf values before the packages are installed."""
|
"""Preseed debconf values before the packages are installed."""
|
||||||
fqdn = socket.getfqdn()
|
fqdn = socket.getfqdn()
|
||||||
domainname = '.'.join(fqdn.split('.')[1:])
|
domainname = '.'.join(fqdn.split('.')[1:])
|
||||||
LOGGER.info('XMPP service domainname will be ', domainname)
|
LOGGER.info('XMPP service domainname will be ' + domainname)
|
||||||
actions.superuser_run('xmpp', ['pre-install', '--domainname', domainname])
|
actions.superuser_run('xmpp', ['pre-install', '--domainname', domainname])
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -56,6 +56,8 @@ class PackageInstallView(TemplateView):
|
|||||||
Start the package installation, and refresh the page every x seconds to
|
Start the package installation, and refresh the page every x seconds to
|
||||||
keep displaying PackageInstallView.get() with the installation status.
|
keep displaying PackageInstallView.get() with the installation status.
|
||||||
"""
|
"""
|
||||||
package_module.start_install(self.kwargs['package_names'],
|
package_module.start_install(
|
||||||
on_install=self.kwargs.get('on_install'))
|
self.kwargs['package_names'],
|
||||||
|
before_install=self.kwargs.get('before_install'),
|
||||||
|
on_install=self.kwargs.get('on_install'))
|
||||||
return self.render_to_response(self.get_context_data())
|
return self.render_to_response(self.get_context_data())
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user