diff options
author | Angel Caido | 2015-07-06 11:11:12 -0400 |
---|---|---|
committer | Angel Caido | 2015-07-06 11:11:12 -0400 |
commit | 1f1a20974047a9fc4540f2d6d441933d23fd30c0 (patch) | |
tree | 7ef607571cc0d65d5d7cab6476076a3b20a51888 | |
download | aur-1f1a20974047a9fc4540f2d6d441933d23fd30c0.tar.gz |
Initial import
-rw-r--r-- | .SRCINFO | 32 | ||||
-rw-r--r-- | PKGBUILD | 75 | ||||
-rw-r--r-- | epoptes-client | 14 | ||||
-rw-r--r-- | epoptes-client.service | 12 | ||||
-rw-r--r-- | epoptes-server.service | 14 | ||||
-rw-r--r-- | epoptes.install | 36 |
6 files changed, 183 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..741a96fa0572 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,32 @@ +pkgbase = epoptes-bzr + pkgdesc = An opensource computer lab management and monitoring tool + pkgver = 0.5.7.426 + pkgrel = 1 + url = https://code.launchpad.net/~epoptes/epoptes/trunk + install = epoptes.install + arch = any + license = GPL3 + makedepends = bzr + makedepends = python2-distutils-extra + depends = python2-dbus + depends = python2-notify + depends = python2-pycha-hg + depends = hicolor-icon-theme + depends = python2-netifaces + depends = python2-pyopenssl + depends = python2-service-identity + depends = python2-twisted + depends = socat + provides = epoptes + conflicts = epoptes + source = bzr+lp:epoptes + source = epoptes-server.service + source = epoptes-client.service + source = epoptes-client + sha256sums = SKIP + sha256sums = 0dd8cc5255798a73f8b88ad8f34a4b7c7340f88dbab65d05d2a74843843c9403 + sha256sums = a7961919235f31a4a2059dda46bf1d0b3b5d20d06d1ce723804634de2443c20f + sha256sums = 64d27face12b754dd01e6b46b511aca11fa348779471d9b9c025cbaf5176aa4d + +pkgname = epoptes-bzr + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..25368263ea62 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,75 @@ +# Maintainer : Angel_Caido <geussepe at gmail dot com> +# Contributor : Sam Stuewe <halosghost at archlinux dot info> + +_name=epoptes +pkgname="${_name}-bzr" +pkgver=0.5.7.426 +pkgrel=1 +pkgdesc='An opensource computer lab management and monitoring tool' +makedepends=('bzr' 'python2-distutils-extra') +url='https://code.launchpad.net/~epoptes/epoptes/trunk' +license=('GPL3') +depends=('python2-dbus' 'python2-notify' 'python2-pycha-hg' 'hicolor-icon-theme' 'python2-netifaces' 'python2-pyopenssl' 'python2-service-identity' 'python2-twisted' 'socat') +arch=('any') +conflicts=("${_name}") +provides=("${_name}") +source=('bzr+lp:epoptes' + 'epoptes-server.service' + 'epoptes-client.service' + 'epoptes-client') +sha256sums=('SKIP' + '0dd8cc5255798a73f8b88ad8f34a4b7c7340f88dbab65d05d2a74843843c9403' + 'a7961919235f31a4a2059dda46bf1d0b3b5d20d06d1ce723804634de2443c20f' + '64d27face12b754dd01e6b46b511aca11fa348779471d9b9c025cbaf5176aa4d') + +install="${_name}".install + +pkgver () { + cd "${srcdir}/${_name}" + printf '%s.%s' "$(bzr tags --sort=time | tail -n1 | cut -d '-' -f1)" "$(bzr revno)" +} + +prepare () { + cd "${srcdir}/${_name}" + sed -e 's/sbin/bin/g' \ + -i setup.py + for i in 'epoptes/ui/benchmark.py' \ + 'epoptes/ui/notifications.py' \ + 'epoptes/daemon/uiconnection.py' \ + 'epoptes/daemon/bashplex.py' \ + 'epoptes/daemon/commands.py' \ + 'epoptes-client/message' \ + 'epoptes/core/wol.py' \ + 'epoptes-client/lock-screen' \ + 'epoptes/core/structs.py' \ + 'epoptes/ui/about_dialog.py' \ + 'epoptes/ui/execcommand.py' \ + 'epoptes/common/config.py' \ + 'epoptes/ui/remote_assistance.py' \ + 'epoptes/ui/gui.py' \ + 'epoptes/common/xdg_dirs.py' \ + 'twisted/plugins/epoptesd.py' \ + 'epoptes/common/ltsconf.py' \ + 'epoptes/ui/sendmessage.py' \ + 'epoptes-client/remote-assistance' \ + 'epoptes-client/screenshot' \ + 'epoptes/common/constants.py' \ + 'epoptes/daemon/guiplex.py' \ + 'epoptes/daemon/exchange.py' \ + 'epoptes/core/lib_users.py' \ + 'epoptes/ui/client_information.py' + do + sed -i '1s+python+python2+' $i + done +} + +package () { + cd "${srcdir}/${_name}" + python2 setup.py install --root="${pkgdir}/" --optimize=1 + mkdir "${pkgdir}/usr/lib/systemd" + mkdir "${pkgdir}/usr/lib/systemd/system" + mkdir "${pkgdir}/etc/default" + install -m 644 "${startdir}/epoptes-client.service" "${pkgdir}"/usr/lib/systemd/system/epoptes-client.service + install -m 644 "${startdir}/epoptes-server.service" "${pkgdir}"/usr/lib/systemd/system/epoptes-server.service + install -m 644 "${startdir}/epoptes-client" "${pkgdir}"/etc/default/epoptes-client +} diff --git a/epoptes-client b/epoptes-client new file mode 100644 index 000000000000..a4d200607b83 --- /dev/null +++ b/epoptes-client @@ -0,0 +1,14 @@ +# The server where epoptes-client will be connecting to. +# If unset, thin client user sessions running on the server will try to connect +# to "localhost", while thin client root sessions and fat or standalone clients +# will try to connect to "server". +# LTSP automatically puts "server" in /etc/hosts for thin and fat clients, +# but you'd need to put "server" in DNS manually for standalone clients. +#SERVER=server + +# The port where the server will be listening on, and where the client will try +# to connect to. For security reasons it defaults to a system port, 789. +#PORT=789 + +# Set Wake On LAN for devices that support it. Comment it out to disable it. +WOL=g diff --git a/epoptes-client.service b/epoptes-client.service new file mode 100644 index 000000000000..0e365c678f47 --- /dev/null +++ b/epoptes-client.service @@ -0,0 +1,12 @@ +[Unit] +Description=Epoptes-client system daemon +Wants=network-online.target +After=network-online.target + +[Service] +EnvironmentFile=-/etc/default/epoptes-client +ExecStartPre=/bin/sh -c "if ! [ -s /etc/epoptes/server.crt ]; then /usr/sbin/epoptes-client -c ${SERVER}; fi" +ExecStart=/usr/sbin/epoptes-client + +[Install] +WantedBy=multi-user.target
\ No newline at end of file diff --git a/epoptes-server.service b/epoptes-server.service new file mode 100644 index 000000000000..1c94218b7563 --- /dev/null +++ b/epoptes-server.service @@ -0,0 +1,14 @@ +# TODO: If this is an LTSP client, then service only should run if EPOPTES=True in lts.conf + +[Unit] +Description=A twisted-based daemon that manages epoptes-client +After=syslog.target + +[Service] +Type=forking +PIDFile=/run/epoptes.pid +ExecStart=/usr/bin/twistd --pidfile /run/epoptes.pid --logfile /var/log/epoptes.log epoptes +#ExecStart=/usr/bin/twistd --pidfile /run/epoptes.pid --logfile /var/log/epoptes.log /usr/bin/epoptes + +[Install] +WantedBy=multi-user.target diff --git a/epoptes.install b/epoptes.install new file mode 100644 index 000000000000..8518fbf00a8d --- /dev/null +++ b/epoptes.install @@ -0,0 +1,36 @@ +post_install() { + gtk-update-icon-cache -q -t -f usr/share/icons/hicolor + mkdir /etc/epoptes + openssl req -batch -x509 -nodes -newkey rsa:1024 -days 3652 -keyout /etc/epoptes/server.key -out /etc/epoptes/server.crt + chmod 600 /etc/epoptes/server.key + if grep -q "epoptes" /etc/group + then + "Group 'epoptes' already exists. Skipping group's creation." + else + groupadd epoptes + echo "Group 'epoptes' has been created." + fi + echo "The installation has finished. Please bare in mind you'll have to do the following before using Epoptes:" + echo "1.- You will have to add yourself to the 'epoptes' group." + echo "2.- You will have to run as root:" + echo " 'systemctl enable epoptes-server' to enable the Epoptes server Daemon." + echo " 'systemctl enable epoptes-client' to enable the Epoptes Client Daemon" + echo "3. You may need to restart your system for everything to work." + echo "4. If you don't want to restart your system, then [after doing all of the above] you will have to run as root:" + echo " 'systemctl start epoptes-server' to start the Epoptes server Daemon." + echo " 'systemctl start epoptes-client' to start the Epoptes server Daemon." + echo "After all this you still have to log out and then log back in and now Epoptes should work without a problem." +} + +post_upgrade() { + systemctl daemon-reload +} + +post_remove() { + rm -rf /etc/epoptes + rm /etc/default/epoptes-client + groupdel epoptes + systemctl daemon-reload + echo "Epoptes has been removed successfully." + +} |