]> git.ipfire.org Git - thirdparty/systemd.git/blame - test/test-execute/exec-bindpaths.service
Merge pull request #14194 from yuwata/network-multipath-routing-12541
[thirdparty/systemd.git] / test / test-execute / exec-bindpaths.service
CommitLineData
f0e018e7
YW
1[Unit]
2Description=Test for BindPaths= and BindReadOnlyPaths=
3
4[Service]
5Type=oneshot
6# Create a file in /tmp/test-exec-bindpaths
42345b17 7ExecStart=touch /tmp/test-exec-bindpaths/thisisasimpletest
f0e018e7 8# Then, the file can be access through /tmp
42345b17 9ExecStart=test -f /tmp/thisisasimpletest
f0e018e7 10# Also, through /tmp/test-exec-bindreadonlypaths
42345b17 11ExecStart=test -f /tmp/test-exec-bindreadonlypaths/thisisasimpletest
f0e018e7
YW
12# The file cannot modify through /tmp/test-exec-bindreadonlypaths
13ExecStart=/bin/sh -x -c '! touch /tmp/test-exec-bindreadonlypaths/thisisasimpletest'
14# Cleanup
42345b17 15ExecStart=rm /tmp/thisisasimpletest
f0e018e7
YW
16BindPaths=/tmp:/tmp/test-exec-bindpaths
17BindReadOnlyPaths=/tmp:/tmp/test-exec-bindreadonlypaths