summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorIwan Timmer2015-11-21 20:33:13 +0100
committerIwan Timmer2015-11-21 20:33:13 +0100
commit99233304ceab5144110f652e525ee1c1dec05bea (patch)
tree2d54a15817e1943a9a3df339b6372ec3e846ee55
parentbde33e13a929d951e4f1d43baa36babca6e46972 (diff)
downloadaur-99233304ceab5144110f652e525ee1c1dec05bea.tar.gz
Fix remotectl missing selinux issue
-rw-r--r--.SRCINFO4
-rw-r--r--PKGBUILD11
-rw-r--r--remotectl-with-empty-selinux.patch25
3 files changed, 35 insertions, 5 deletions
diff --git a/.SRCINFO b/.SRCINFO
index ba720a3985e4..54375a594cda 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = cockpit
pkgdesc = A systemd web based user interface for Linux servers
pkgver = 0.84
- pkgrel = 1
+ pkgrel = 2
url = http://www.cockpit-project.org/
arch = i686
arch = x86_64
@@ -32,7 +32,9 @@ pkgbase = cockpit
optdepends = networkmanager
conflicts = cockpit-git
source = https://github.com/cockpit-project/cockpit/archive/0.84.tar.gz
+ source = remotectl-with-empty-selinux.patch
sha1sums = 55ab248fa174f1bd16c8d77cf704e33ebc4b1e5d
+ sha1sums = c18aae424cd724178bbd0502b9aae17e15f861f8
pkgname = cockpit
diff --git a/PKGBUILD b/PKGBUILD
index 842d2b0c3164..a13913dfaba0 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -4,7 +4,7 @@
pkgname=cockpit
pkgver=0.84
-pkgrel=1
+pkgrel=2
pkgdesc='A systemd web based user interface for Linux servers'
arch=(i686 x86_64 armv6h armv7h)
url='http://www.cockpit-project.org/'
@@ -13,11 +13,14 @@ conflicts=(cockpit-git)
depends=(libssh krb5 sshpass accountsservice perl-json perl-locale-po json-glib pcp glib-networking)
makedepends=(git intltool python2-pyscss gtk-doc perl-javascript-minifier-xs gobject-introspection networkmanager libgsystem xmlto npm)
optdepends=(storaged udisks2 networkmanager)
-source=(https://github.com/cockpit-project/cockpit/archive/${pkgver}.tar.gz)
-sha1sums=('55ab248fa174f1bd16c8d77cf704e33ebc4b1e5d')
+source=(https://github.com/cockpit-project/cockpit/archive/${pkgver}.tar.gz
+ remotectl-with-empty-selinux.patch)
+sha1sums=('55ab248fa174f1bd16c8d77cf704e33ebc4b1e5d'
+ 'c18aae424cd724178bbd0502b9aae17e15f861f8')
prepare() {
- cd cockpit-${pkgver}
+ cd "${srcdir}"/${pkgname}-${pkgver}
+ patch -Np1 -i ../remotectl-with-empty-selinux.patch
}
build() {
diff --git a/remotectl-with-empty-selinux.patch b/remotectl-with-empty-selinux.patch
new file mode 100644
index 000000000000..53e6eaa24a0d
--- /dev/null
+++ b/remotectl-with-empty-selinux.patch
@@ -0,0 +1,25 @@
+From 6246c16d0bed3ce63f3b598684849823d8661282 Mon Sep 17 00:00:00 2001
+From: Stef Walter <stefw@redhat.com>
+Date: Thu, 19 Nov 2015 12:24:25 +0100
+Subject: [PATCH] remotectl: Don't try to run chcon with an empty SELinux
+ context
+
+Closes #3186
+Reviewed-by: Peter <petervo@redhat.com>
+---
+ src/remotectl/certificate.c | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/src/remotectl/certificate.c b/src/remotectl/certificate.c
+index 9aacac9..45d5c15 100644
+--- a/src/remotectl/certificate.c
++++ b/src/remotectl/certificate.c
+@@ -128,6 +128,8 @@ ensure_certificate (const gchar *user,
+ goto out;
+ }
+
++ if (g_strcmp0 (selinux, "") == 0)
++ selinux = NULL;
+ if (selinux)
+ {
+ chcon_argv[3] = path;