]> git.ipfire.org Git - thirdparty/systemd.git/blob - test/test-execute/exec-temporaryfilesystem-usr.service
tests: add spdx license header to test unit/link/network/conf files
[thirdparty/systemd.git] / test / test-execute / exec-temporaryfilesystem-usr.service
1 # SPDX-License-Identifier: LGPL-2.1-or-later
2 [Unit]
3 Description=Test for TemporaryFileSystem on /usr
4
5 [Service]
6 Type=oneshot
7
8 # Check TemporaryFileSystem= are empty
9 ExecStart=/bin/sh -c 'for i in $$(ls -A /usr); do test $$i = lib -o $$i = lib64 -o $$i = bin -o $$i = sbin || false; done'
10
11 # Cannot create files under /usr
12 ExecStart=/bin/sh -c '! touch /usr/hoge'
13 ExecStart=/bin/sh -c '! touch /usr/bin/hoge'
14
15 TemporaryFileSystem=/usr:ro
16 BindReadOnlyPaths=-/usr/lib -/usr/lib64 /usr/bin /usr/sbin