repro: Remove app

The repro app has been disabled for a long time. Its package has been
removed from Debian, and there is no sign of it returning soon.

Signed-off-by: James Valleroy <jvalleroy@mailbox.org>
This commit is contained in:
James Valleroy 2020-01-15 22:31:26 -05:00
parent c8a5f3727f
commit 21ba450484
No known key found for this signature in database
GPG Key ID: 77C0C75E7B650808
15 changed files with 1 additions and 712 deletions

View File

@ -1,75 +0,0 @@
#!/usr/bin/python3
#
# This file is part of FreedomBox.
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as
# published by the Free Software Foundation, either version 3 of the
# License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
"""
Configuration helper for repro SIP proxy.
"""
import argparse
from plinth import action_utils
CONFIG = '/etc/repro/repro.config'
def parse_arguments():
"""Return parsed command line arguments as dictionary."""
parser = argparse.ArgumentParser()
subparsers = parser.add_subparsers(dest='subcommand', help='Sub command')
subparsers.add_parser('setup', help='Configure repro')
subparsers.required = True
return parser.parse_args()
def subcommand_setup(_):
"""Configure repro."""
with open(CONFIG, 'r') as conf:
lines = conf.readlines()
with open(CONFIG, 'w') as conf:
for line in lines:
if line.startswith('Database1Path'):
# workaround for Debian bug #803113
conf.write('Database1Path = /var/lib/repro\n')
elif line.startswith('TLSPort'):
conf.write('TLSPort = 5061\n')
elif line.startswith('DisableHttpAuth'):
# let apache handle authentication
conf.write('DisableHttpAuth = true\n')
else:
conf.write(line)
action_utils.service_restart('repro')
# We have introduced new firewalld service files and wish to use
# them.
action_utils.service_reload('firewalld')
def main():
"""Parse arguments and perform all duties."""
arguments = parse_arguments()
subcommand = arguments.subcommand.replace('-', '_')
subcommand_method = globals()['subcommand_' + subcommand]
subcommand_method(arguments)
if __name__ == '__main__':
main()

2
debian/copyright vendored
View File

@ -56,8 +56,6 @@ Files: static/themes/default/icons/diaspora.png
static/themes/default/icons/privoxy.png
static/themes/default/icons/privoxy.svg
static/themes/default/icons/radicale.svg
static/themes/default/icons/repro.png
static/themes/default/icons/repro.svg
static/themes/default/img/network-*
Copyright: None
Comment: Placed into public domain by authors (or)

View File

@ -8,3 +8,4 @@ rm_conffile /etc/plinth/modules-enabled/system 0.15.1+ds-2~
rm_conffile /etc/plinth/modules-enabled/disks 0.15.3+ds-1~
rm_conffile /etc/plinth/modules-enabled/udiskie 0.39.0~
rm_conffile /etc/plinth/modules-enabled/restore 20.1~
rm_conffile /etc/plinth/modules-enabled/repro 20.1~

View File

@ -1,43 +0,0 @@
#
# This file is part of FreedomBox.
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as
# published by the Free Software Foundation, either version 3 of the
# License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
# XXX: Enable tests when repro module is enabled again.
@apps @sip @backups @sso @skip
Feature: Repro SIP Server
Make audio and video calls.
Background:
Given I'm a logged in user
Given the repro application is installed
Scenario: Enable repro application
Given the repro application is disabled
When I enable the repro application
Then the repro service should be running
Scenario: Backup and restore repro
Given the repro application is enabled
And repro has been configured
When I create a backup of the repro app data
And I delete the repro configuration
And I restore the repro app data backup
Then the repro configuration should be restored
Scenario: Disable repro application
Given the repro application is enabled
When I disable the repro application
Then the repro service should not be running

View File

@ -138,21 +138,6 @@ def mldonkey_assert_number_of_ed2k_files(browser, ed2k_files_number):
assert ed2k_files_number == site.mldonkey_get_number_of_ed2k_files(browser)
@given('repro has been configured')
def repro_configure(browser):
site.repro_configure(browser)
@when('I delete the repro configuration')
def repro_delete_config(browser):
site.repro_delete_config(browser)
@then('the repro configuration should be restored')
def repro_is_configured(browser):
assert site.repro_is_configured(browser)
@when('all torrents are removed from transmission')
def transmission_remove_all_torrents(browser):
site.transmission_remove_all_torrents(browser)

View File

@ -171,32 +171,6 @@ def _mediawiki_has_main_page(browser):
return 'This page has been deleted.' not in content.text
def repro_configure(browser):
"""Configure repro."""
browser.visit(
'{}/repro/domains.html?domainUri=freedombox.local&domainTlsPort='
'&action=Add'.format(interface.default_url))
def repro_delete_config(browser):
"""Delete the repro config."""
browser.visit('{}/repro/domains.html?domainUri=&domainTlsPort='
'&action=Remove&remove.freedombox.local=on'.format(
interface.default_url))
def repro_is_configured(browser):
"""Check whether repro is configured."""
return eventually(_repro_is_configured, [browser])
def _repro_is_configured(browser):
"""Check whether repro is configured."""
browser.visit('{}/repro/domains.html'.format(interface.default_url))
remove = browser.find_by_name('remove.freedombox.local')
return bool(remove)
def jsxc_login(browser):
"""Login to JSXC."""
access_url(browser, 'jsxc')

View File

@ -1,134 +0,0 @@
#
# This file is part of FreedomBox.
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as
# published by the Free Software Foundation, either version 3 of the
# License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
"""
FreedomBox app for repro.
"""
from django.urls import reverse_lazy
from django.utils.translation import ugettext_lazy as _
from plinth import actions
from plinth import app as app_module
from plinth import frontpage, menu
from plinth.daemon import Daemon
from plinth.modules.apache.components import Webserver
from plinth.modules.firewall.components import Firewall
from plinth.views import AppView
from .manifest import backup, clients # noqa, pylint: disable=unused-import
version = 2
managed_services = ['repro']
managed_packages = ['repro']
name = _('repro')
short_description = _('SIP Server')
description = [
_('repro provides various SIP services that a SIP softphone can utilize '
'to provide audio and video calls as well as presence and instant '
'messaging. repro provides a server and SIP user accounts that clients '
'can use to let their presence known. It also acts as a proxy to '
'federate SIP communications to other servers on the Internet similar '
'to email.'),
_('To make SIP calls, a client application is needed. Available clients '
'include <a href="https://jitsi.org/">Jitsi</a> (for computers) and '
'<a href="https://f-droid.org/repository/browse/?fdid=com.csipsimple"> '
'CSipSimple</a> (for Android phones).'),
_('<strong>Note:</strong> Before using repro, domains and users will '
'need to be configured using the <a href="/repro/domains.html" '
'data-turbolinks="false">web-based configuration panel</a>. Users in '
'the <em>admin</em> group will be able to log in to the repro '
'configuration panel. After setting the domain, it is required to '
'restart the repro service. Disable the service and re-enable it.'),
]
clients = clients
reserved_usernames = ['repro']
manual_page = 'Repro'
port_forwarding_info = [('UDP', '1024-65535')]
app = None
class ReproApp(app_module.App):
"""FreedomBox app for Repro."""
app_id = 'repro'
def __init__(self):
"""Create components for the app."""
super().__init__()
menu_item = menu.Menu('menu-repro', name, short_description, 'repro',
'repro:index', parent_url_name='apps')
self.add(menu_item)
shortcut = frontpage.Shortcut(
'shortcut-repro', name, short_description=short_description,
icon='repro', description=description,
configure_url=reverse_lazy('repro:index'), clients=clients,
login_required=True)
self.add(shortcut)
firewall = Firewall('firewall-repro', name,
ports=['sip', 'sips',
'rtp-plinth'], is_external=True)
self.add(firewall)
webserver = Webserver('webserver-repro', 'repro-plinth')
self.add(webserver)
daemon = Daemon(
'daemon-repro', managed_services[0], listen_ports=[(5060, 'udp4'),
(5060, 'udp6'),
(5060, 'tcp4'),
(5060, 'tcp6'),
(5061, 'tcp4'),
(5061, 'tcp6')])
self.add(daemon)
def init():
"""Initialize the repro module."""
global app
app = ReproApp()
setup_helper = globals()['setup_helper']
if setup_helper.get_state() != 'needs-setup' and app.is_enabled():
app.set_enabled(True)
class ReproAppView(AppView):
clients = clients
name = name
description = description
app_id = 'repro'
manual_page = manual_page
port_forwarding_info = port_forwarding_info
def setup(helper, old_version=None):
"""Install and configure the module."""
helper.install(managed_packages)
helper.call('post', actions.superuser_run, 'repro', ['setup'])
helper.call('post', app.enable)

View File

@ -1,11 +0,0 @@
##
## On all sites, provide repro admin interface on a path: /repro
## Only allow users of admin LDAP group.
##
<Location /repro>
ProxyPass http://localhost:5080
Include includes/freedombox-single-sign-on.conf
<IfModule mod_auth_pubtkt.c>
TKTAuthToken "admin"
</IfModule>
</Location>

View File

@ -1 +0,0 @@
#plinth.modules.repro

View File

@ -1,6 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<service>
<short>Real-time Transport Protocol</short>
<description>RTP is a protocol for delivering real-time data such as audio and video. Enable this if you run an internet telephony server using XMPP, SIP or H.323 and wish to enable audio and video communications.</description>
<port protocol="udp" port="1024-65535"/>
</service>

View File

@ -1,90 +0,0 @@
#
# This file is part of FreedomBox.
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as
# published by the Free Software Foundation, either version 3 of the
# License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
from django.utils.translation import ugettext_lazy as _
from plinth.modules.backups.api import validate as validate_backup
from plinth.clients import store_url, validate
_jitsi_package_id = 'org.jitsi.meet'
_csipsimple_package_id = 'com.csipsimple'
_jitsi_download_url = 'https://download.jitsi.org/jitsi/'
clients = validate([{
'name':
_('Jitsi Meet'),
'description':
_('Jitsi is a set of open-source projects that allows '
'you to easily build and deploy secure '
'videoconferencing solutions. At the heart of Jitsi '
'are Jitsi Videobridge and Jitsi Meet, which let you '
'have conferences on the internet, while other '
'projects in the community enable other features '
'such as audio, dial-in, recording, '
'and simulcasting.'),
'platforms': [{
'type': 'store',
'os': 'android',
'store_name': 'google-play',
'url': store_url('google-play', _jitsi_package_id)
}, {
'type': 'store',
'os': 'ios',
'store_name': 'app-store',
'url': 'https://itunes.apple.com/in/app/jitsi-meet/id1165103905'
}, {
'type': 'download',
'os': 'gnu-linux',
'url': _jitsi_download_url
}, {
'type': 'package',
'format': 'deb',
'name': 'jitsi'
}, {
'type': 'download',
'os': 'macos',
'url': _jitsi_download_url
}, {
'type': 'download',
'os': 'windows',
'url': _jitsi_download_url
}]
}, {
'name':
_('CSipSimple'),
'platforms': [{
'type': 'store',
'os': 'android',
'store_name': 'google-play',
'url': store_url('google-play', _csipsimple_package_id)
}]
}])
backup = validate_backup({
'config': {
'files': ['/etc/repro/repro.config', '/etc/repro/users.txt']
},
'data': {
'directories': ['/var/lib/repro/']
},
'secrets': {
'directories': ['/etc/repro/ssl/'],
'files': ['/etc/repro/dh2048.pem']
},
'services': ['repro']
})

View File

@ -1,27 +0,0 @@
#
# This file is part of FreedomBox.
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as
# published by the Free Software Foundation, either version 3 of the
# License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
"""
URLs for the repro module.
"""
from django.conf.urls import url
from plinth.modules.repro import ReproAppView
urlpatterns = [
url(r'^apps/repro/$', ReproAppView.as_view(), name='index'),
]

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.7 KiB

View File

@ -1,282 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
xmlns:ns6="http://ns.adobe.com/SaveForWeb/1.0/"
xmlns:ns5="http://ns.adobe.com/Variables/1.0/"
xmlns:ns4="http://ns.adobe.com/AdobeIllustrator/10.0/"
xmlns:a="http://ns.adobe.com/AdobeSVGViewerExtensions/3.0/"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
ns4:viewOrigin="118.9321 582.0679"
ns4:rulerOrigin="0 0"
ns4:pageBounds="0 612 792 0"
width="512"
height="512"
viewBox="0 0 512.00001 512.00001"
overflow="visible"
enable-background="new 0 0 552.068 552.068"
xml:space="preserve"
version="1.1"
id="svg959"
sodipodi:docname="repro.svg"
inkscape:version="0.92.4 (5da689c313, 2019-01-14)"
style="overflow:visible"><defs
id="defs963" /><sodipodi:namedview
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1"
objecttolerance="10"
gridtolerance="10"
guidetolerance="10"
inkscape:pageopacity="0"
inkscape:pageshadow="2"
inkscape:window-width="1853"
inkscape:window-height="1527"
id="namedview961"
showgrid="false"
inkscape:zoom="1.2552161"
inkscape:cx="273.58331"
inkscape:cy="216.38186"
inkscape:window-x="1391"
inkscape:window-y="256"
inkscape:window-maximized="0"
inkscape:current-layer="g955"
fit-margin-top="0"
fit-margin-left="0"
fit-margin-right="0"
fit-margin-bottom="0" />
<metadata
id="metadata834">
<ns5:variableSets>
<ns5:variableSet
varSetName="binding1"
locked="none">
<ns5:variables />
<ns5:sampleDataSets />
</ns5:variableSet>
</ns5:variableSets>
<ns6:sfw>
<ns6:slices />
<ns6:sliceSourceBounds
y="30"
x="118.932"
width="552.068"
height="552.068"
bottomLeftOrigin="true" />
</ns6:sfw>
<rdf:RDF><cc:Work
rdf:about=""><dc:format>image/svg+xml</dc:format><dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" /><dc:title></dc:title></cc:Work></rdf:RDF></metadata>
<g
id="g955"
ns4:extraneous="self"
transform="translate(-6.375,65.079994)">
<g
id="g900"
transform="matrix(0.94146202,0,0,0.94146202,0.3731808,-71.332713)">
<linearGradient
id="XMLID_6_"
gradientUnits="userSpaceOnUse"
x1="102.3462"
y1="279.3511"
x2="414.00629"
y2="279.3511"
gradientTransform="matrix(-1,0,0,1,535.6377,0)">
<stop
offset="0"
style="stop-color:#FFFFFF"
id="stop877" />
<stop
offset="0.0028"
style="stop-color:#FEFEFE"
id="stop879" />
<stop
offset="0.1595"
style="stop-color:#BCBCBC"
id="stop881" />
<stop
offset="0.3135"
style="stop-color:#828282"
id="stop883" />
<stop
offset="0.4609"
style="stop-color:#545454"
id="stop885" />
<stop
offset="0.6005"
style="stop-color:#2F2F2F"
id="stop887" />
<stop
offset="0.7302"
style="stop-color:#151515"
id="stop889" />
<stop
offset="0.8466"
style="stop-color:#060606"
id="stop891" />
<stop
offset="0.9382"
style="stop-color:#000000"
id="stop893" />
<a:midPointStop
offset="0"
style="stop-color:#FFFFFF" />
<a:midPointStop
offset="0.3434"
style="stop-color:#FFFFFF" />
<a:midPointStop
offset="0.9382"
style="stop-color:#000000" />
</linearGradient>
<path
d="m 121.631,322.3 h 311.66 v -85.899 h -311.66 z"
id="path896"
style="fill:url(#XMLID_6_)"
inkscape:connector-curvature="0" />
<path
d="M 123.35,194.059 V 362.412 L 6.375,279.689 Z"
id="path898"
inkscape:connector-curvature="0" />
</g>
<g
id="g926"
transform="matrix(0.94146202,0,0,0.94146202,0.3731808,-71.332713)">
<linearGradient
id="XMLID_7_"
gradientUnits="userSpaceOnUse"
x1="123.293"
y1="363.85889"
x2="434.95361"
y2="363.85889">
<stop
offset="0"
style="stop-color:#FFFFFF"
id="stop903" />
<stop
offset="0.0028"
style="stop-color:#FEFEFE"
id="stop905" />
<stop
offset="0.1595"
style="stop-color:#BCBCBC"
id="stop907" />
<stop
offset="0.3135"
style="stop-color:#828282"
id="stop909" />
<stop
offset="0.4609"
style="stop-color:#545454"
id="stop911" />
<stop
offset="0.6005"
style="stop-color:#2F2F2F"
id="stop913" />
<stop
offset="0.7302"
style="stop-color:#151515"
id="stop915" />
<stop
offset="0.8466"
style="stop-color:#060606"
id="stop917" />
<stop
offset="0.9382"
style="stop-color:#000000"
id="stop919" />
<a:midPointStop
offset="0"
style="stop-color:#FFFFFF" />
<a:midPointStop
offset="0.3434"
style="stop-color:#FFFFFF" />
<a:midPointStop
offset="0.9382"
style="stop-color:#000000" />
</linearGradient>
<path
d="M 434.954,406.808 H 123.293 v -85.899 h 311.661 z"
id="path922"
style="fill:url(#XMLID_7_)"
inkscape:connector-curvature="0" />
<path
d="M 433.235,278.567 V 446.92 L 550.21,364.197 Z"
id="path924"
inkscape:connector-curvature="0" />
</g>
<g
id="g952"
transform="matrix(0.94146202,0,0,0.94146202,0.3731808,-71.332713)">
<linearGradient
id="XMLID_8_"
gradientUnits="userSpaceOnUse"
x1="123.293"
y1="195.4897"
x2="434.95361"
y2="195.4897">
<stop
offset="0"
style="stop-color:#FFFFFF"
id="stop929" />
<stop
offset="0.0028"
style="stop-color:#FEFEFE"
id="stop931" />
<stop
offset="0.1595"
style="stop-color:#BCBCBC"
id="stop933" />
<stop
offset="0.3135"
style="stop-color:#828282"
id="stop935" />
<stop
offset="0.4609"
style="stop-color:#545454"
id="stop937" />
<stop
offset="0.6005"
style="stop-color:#2F2F2F"
id="stop939" />
<stop
offset="0.7302"
style="stop-color:#151515"
id="stop941" />
<stop
offset="0.8466"
style="stop-color:#060606"
id="stop943" />
<stop
offset="0.9382"
style="stop-color:#000000"
id="stop945" />
<a:midPointStop
offset="0"
style="stop-color:#FFFFFF" />
<a:midPointStop
offset="0.3434"
style="stop-color:#FFFFFF" />
<a:midPointStop
offset="0.9382"
style="stop-color:#000000" />
</linearGradient>
<path
d="M 434.954,238.439 H 123.293 V 152.54 h 311.661 z"
id="path948"
style="fill:url(#XMLID_8_)"
inkscape:connector-curvature="0" />
<path
d="M 433.235,110.198 V 278.55 L 550.21,195.827 Z"
id="path950"
inkscape:connector-curvature="0" />
</g>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 6.7 KiB