Skip to content

Commit 9b06aad

Browse files
vojtechtrefnyrichm
authored andcommitted
fix: Allow running on systems without /etc/fstab present
When /etc/fstab is not present, we'll simply skip parsing it. Fixes: #557 Resolves: RHEL-115033
1 parent b883213 commit 9b06aad

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

library/blivet.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2186,6 +2186,9 @@ def parse(self):
21862186
if self._entries:
21872187
self.reset()
21882188

2189+
if not os.path.exists('/etc/fstab'):
2190+
return
2191+
21892192
with open('/etc/fstab') as f:
21902193
for line in f.readlines():
21912194
if line.lstrip().startswith("#"):

0 commit comments

Comments
 (0)