mirror of
https://github.com/nix-community/disko.git
synced 2026-11-30 21:13:28 +01:00
types swap: check real path of the device before mount
This commit is contained in:
1 parent
96815862d8
commit
c77e66cea1
1 file changed
+1
-1
+1
-1
@@ -42,7 +42,7 @@
|
||||
inherit config options;
|
||||
default = {
|
||||
fs.${config.device} = ''
|
||||
if ! swapon --show | grep -q '^${config.device} '; then
|
||||
if ! swapon --show | grep -q "^$(readlink -f ${config.device}) "; then
|
||||
swapon ${config.device}
|
||||
fi
|
||||
'';
|
||||
|
||||
Reference in new issue
Block a user