Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Allow rsync to deal with lock files

Signed-off-by: Lon Hohberger <lhh@redhat.com>
Tested-by: Martina Kollarova <mkollaro@redhat.com>
  • Loading branch information...
commit 6fa94c476c307427dff99ecac1199e2730e33a07 1 parent 445458c
@rhatdan rhatdan authored Lon Hohberger committed
Showing with 38 additions and 1 deletion.
  1. +1 −1  Makefile
  2. +37 −0 openstack-rsync.te
View
2  Makefile
@@ -1,4 +1,4 @@
-TARGETS?=openstack-selinux-nova openstack-selinux-quantum swift
+TARGETS?=openstack-selinux-nova openstack-selinux-quantum swift openstack-rsync
MODULES?=${TARGETS:=.pp.bz2}
SHAREDIR?=/usr/share
#INSTALL=?=install
View
37 openstack-rsync.te
@@ -0,0 +1,37 @@
+#
+# SELinux policy module for OpenStack Swift running rsync
+# Copyright 2013 Red Hat, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation version 2.
+#
+# 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 General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License along
+# with this program; if not, write to the Free Software Foundation, Inc.,
+# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+#
+
+#
+# Allow rsync operating under swift to deal with rsync lock files
+# Author: Dan Walsh <dwalsh@redhat.com>
+#
+policy_module(openstack-rsync, 0.4)
+
+require {
+ type rsync_t;
+}
+
+
+files_manage_generic_locks(rsync_t)
+
+# Compile with:
+# make -f /usr/share/selinux/devel/Makefile
+# Install:
+# semodule -i openstack-selinux-nova.pp
+# Remove:
+# semodule -r openstack-selinux-nova
Please sign in to comment.
Something went wrong with that request. Please try again.