repo.or.cz
/
tails.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
chdir / makes paths more predictable
[tails.git]
/
config
/
chroot_local-includes
/
sbin
/
swapon.tails
blob
22d684c28de7ae57271b02ba544c4999b2656a9f
1
#!/bin/sh
2
3
set -eu
4
5
cd
/
6
7
for
param
in
"$@"
;
do
8
if
echo
"
${param}
"
|
grep
-v
'^/dev/zram'
|
grep
-q
/;
then
9
echo
>&
2
"Setting up swap is only allowed for zram devices"
10
exit
1
11
fi
12
done
13
14
exec
/
sbin
/
swapon.distrib
"$@"
15