Browse code

Add another example to file_secontext.yml

Demonstrate what happens when there is no default context in the policy.

Stephen Fromm authored on 2012/04/22 16:14:40
Showing 1 changed files
... ...
@@ -9,4 +9,10 @@
9 9
       action: file path=/etc/exports seuser=unconfined_u
10 10
     - name: Set selinux context back to default value
11 11
       action: file path=/etc/exports context=default
12
-  
12
+    - name: Create empty file
13
+      action: command /bin/touch /tmp/foo
14
+    - name: Change setype of /tmp/foo
15
+      action: file path=/tmp/foo setype=default_t
16
+    - name: Try to set secontext to default, but this will fail
17
+            because of the lack of a default in the policy
18
+      action: file path=/tmp/foo context=default