mirror of
https://github.com/nix-community/disko.git
synced 2024-09-17 09:37:17 +03:00
types swap: check real path of the device before mount
This commit is contained in:
parent
96815862d8
commit
c77e66cea1
@ -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
|
||||
'';
|
||||
|
Loading…
Reference in New Issue
Block a user