summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlejandro Sirgo Rica <asirgo@soleta.eu>2024-05-15 13:43:22 +0200
committerAlejandro Sirgo Rica <asirgo@soleta.eu>2024-05-16 12:17:21 +0200
commitf896107375cc2a47a5c4eb3095c6c365d8eed98e (patch)
tree41cfcad876d3a0e9b03f3bacb32c505469f4cb48
parent8e60e95df6138566ebdf93a7ff74f2badcd98a86 (diff)
views: check if EFI filesystem is FAT32 in partition form
Add validation for partition and format form to ensure the EFI partition has a FAT32 filesystem assigned.
-rw-r--r--ogcp/views.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/ogcp/views.py b/ogcp/views.py
index 056c3e5..d02359b 100644
--- a/ogcp/views.py
+++ b/ogcp/views.py
@@ -648,6 +648,10 @@ def action_setup_modify():
if partition.part_type.data == 'CACHE':
cache_count += 1
+ if partition.part_type.data == 'EFI' and partition.fs.data != 'FAT32':
+ flash(_('The EFI partition requires a FAT32 filesystem'), category='error')
+ return redirect(url_for('commands'))
+
if cache_count == 0:
flash(_(f'Missing cache partition'), category='error')
return redirect(url_for('commands'))