Skip to content
GitLab
Explore
Projects
Groups
Topics
Snippets
Projects
Groups
Topics
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
fusiondirectory
fusiondirectory-plugins
Commits
0461d118
Commit
0461d118
authored
6 years ago
by
Côme Chilliet
Browse files
Options
Download
Patches
Plain Diff
feat(fai) Add support for randinit option, fix mount option support
issue #5821
parent
bd4b9598
dev
6104-mail-methods-refactor
6231-give-the-ability-to-the-webservice-to-notice-if-an-attribute-is-monovalued-or-multivalued
6237-add-requiredattrs-array-to-the-webservice-informations
6245-adapt-the-ci-to-the-reorganisation-of-the-dev-tools-and-fixing-the-trigger-downstream-pipelines
6250-supann-configuration-backend-requires-account-life-cycle-section
6280-plugins-update-plugins-to-take-into-consideration-the-new-directory-of-core-structure
6310-tasks-reminder-error-in-the-schema-duplicate-attribute-id
6311-put-the-version-1-5-in-all-yaml-for-fusiondirectory-1-5
6322-template-issue-when-creating-a-template-with-empty-password-error-message-should-not-be-seen-2
6332-zimbra-allows-update-of-data-for-unknown-domain-name-for-specific-individual-aliases
6337-webservice-issue-with-archiving-post-request-not-responding-but-successfully-archiving-user
6341-supann-extract-resources-states-sub-states-from-backend-configuration-to-their-own-objects
6346-lifecycle-adaptation-to-select-supann-resources-and-related-states-via-regex-mechanism
master
fusiondirectory-1.5
fusiondirectory-1.4
fusiondirectory-1.3.1
fusiondirectory-1.3
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
fai/admin/fai/class_faiDiskEntry.inc
+17
-1
fai/admin/fai/class_faiDiskEntry.inc
fai/admin/fai/class_faiPartition.inc
+6
-4
fai/admin/fai/class_faiPartition.inc
fai/admin/fai/class_faiPartitionTable.inc
+5
-4
fai/admin/fai/class_faiPartitionTable.inc
with
28 additions
and
9 deletions
+28
-9
fai/admin/fai/class_faiDiskEntry.inc
+
17
−
1
View file @
0461d118
...
@@ -259,6 +259,10 @@ class faiDiskEntry extends simplePlugin
...
@@ -259,6 +259,10 @@ class faiDiskEntry extends simplePlugin
array
(
'msdos'
,
'gpt'
),
''
,
array
(
'msdos'
,
'gpt'
),
''
,
array
(
'MSDOS'
,
'GPT'
)
array
(
'MSDOS'
,
'GPT'
)
),
),
new
BooleanAttribute
(
_
(
'Random init'
),
_
(
'Initialise all encrypted partitions with random data'
),
'randinit'
,
FALSE
),
new
HiddenAttribute
(
'FAIdiskType'
)
new
HiddenAttribute
(
'FAIdiskType'
)
)
)
),
),
...
@@ -299,6 +303,9 @@ class faiDiskEntry extends simplePlugin
...
@@ -299,6 +303,9 @@ class faiDiskEntry extends simplePlugin
if
(
$this
->
FAIdiskType
==
'cryptsetup'
)
{
if
(
$this
->
FAIdiskType
==
'cryptsetup'
)
{
$this
->
attributesAccess
[
'fstabkey'
]
->
setDisabled
(
TRUE
);
$this
->
attributesAccess
[
'fstabkey'
]
->
setDisabled
(
TRUE
);
$this
->
attributesAccess
[
'fstabkey'
]
->
setVisible
(
FALSE
);
$this
->
attributesAccess
[
'fstabkey'
]
->
setVisible
(
FALSE
);
}
else
{
$this
->
attributesAccess
[
'randinit'
]
->
setDisabled
(
TRUE
);
$this
->
attributesAccess
[
'randinit'
]
->
setVisible
(
FALSE
);
}
}
if
(
$disk
)
{
if
(
$disk
)
{
...
@@ -366,6 +373,11 @@ class faiDiskEntry extends simplePlugin
...
@@ -366,6 +373,11 @@ class faiDiskEntry extends simplePlugin
}
}
continue
;
continue
;
}
}
if
(
$option
==
'randinit'
)
{
$this
->
randinit
=
TRUE
;
continue
;
}
}
}
}
}
...
@@ -434,7 +446,11 @@ class faiDiskEntry extends simplePlugin
...
@@ -434,7 +446,11 @@ class faiDiskEntry extends simplePlugin
if
(
$this
->
FAIdiskType
==
'disk'
)
{
if
(
$this
->
FAIdiskType
==
'disk'
)
{
$tmp
[
'FAIdiskOption'
]
=
array
(
'fstabkey:'
.
$this
->
fstabkey
,
'disklabel:'
.
$this
->
disklabel
);
$tmp
[
'FAIdiskOption'
]
=
array
(
'fstabkey:'
.
$this
->
fstabkey
,
'disklabel:'
.
$this
->
disklabel
);
}
elseif
(
$this
->
FAIdiskType
==
'cryptsetup'
)
{
}
elseif
(
$this
->
FAIdiskType
==
'cryptsetup'
)
{
$tmp
[
'FAIdiskOption'
]
=
array
();
if
(
$this
->
randinit
)
{
$tmp
[
'FAIdiskOption'
]
=
array
(
'randinit'
);
}
else
{
$tmp
[
'FAIdiskOption'
]
=
array
();
}
}
else
{
}
else
{
$tmp
[
'FAIdiskOption'
]
=
array
(
'fstabkey:'
.
$this
->
fstabkey
);
$tmp
[
'FAIdiskOption'
]
=
array
(
'fstabkey:'
.
$this
->
fstabkey
);
}
}
...
...
This diff is collapsed.
Click to expand it.
fai/admin/fai/class_faiPartition.inc
+
6
−
4
View file @
0461d118
...
@@ -330,6 +330,11 @@ class faiPartition extends simplePlugin
...
@@ -330,6 +330,11 @@ class faiPartition extends simplePlugin
'options'
=>
array
(
'options'
=>
array
(
'name'
=>
_
(
'Options'
),
'name'
=>
_
(
'Options'
),
'attrs'
=>
array
(
'attrs'
=>
array
(
new
StringAttribute
(
_
(
'Mount options'
),
_
(
'Filesystem mount options'
),
'FAImountOptions'
,
FALSE
,
'defaults'
),
new
StringAttribute
(
new
StringAttribute
(
_
(
'Create options'
),
_
(
'Filesystem create options'
),
_
(
'Create options'
),
_
(
'Filesystem create options'
),
'FAIfsCreateOptions'
,
FALSE
'FAIfsCreateOptions'
,
FALSE
...
@@ -338,10 +343,6 @@ class faiPartition extends simplePlugin
...
@@ -338,10 +343,6 @@ class faiPartition extends simplePlugin
_
(
'Tune options'
),
_
(
'Filesystem tune options'
),
_
(
'Tune options'
),
_
(
'Filesystem tune options'
),
'FAIfsTuneOptions'
,
FALSE
'FAIfsTuneOptions'
,
FALSE
),
),
new
StringAttribute
(
_
(
'Mount options'
),
_
(
'Filesystem mount options'
),
'FAIfsOptions'
,
FALSE
),
)
)
)
)
);
);
...
@@ -427,6 +428,7 @@ class faiPartition extends simplePlugin
...
@@ -427,6 +428,7 @@ class faiPartition extends simplePlugin
if
(
$this
->
FAIdiskType
==
'cryptsetup'
)
{
if
(
$this
->
FAIdiskType
==
'cryptsetup'
)
{
$this
->
attributesAccess
[
'cryptsetupPartition'
]
->
setChoices
(
$this
->
getPartitionList
());
$this
->
attributesAccess
[
'cryptsetupPartition'
]
->
setChoices
(
$this
->
getPartitionList
());
$this
->
attributesAccess
[
'cryptsetupPartition'
]
->
setRequired
(
TRUE
);
$this
->
attributesAccess
[
'FAIpartitionSize'
]
->
setDisabled
(
TRUE
);
$this
->
attributesAccess
[
'FAIpartitionSize'
]
->
setDisabled
(
TRUE
);
$this
->
attributesAccess
[
'FAIpartitionSize'
]
->
setVisible
(
FALSE
);
$this
->
attributesAccess
[
'FAIpartitionSize'
]
->
setVisible
(
FALSE
);
$this
->
attributesInfo
[
'flags'
][
'name'
]
=
_
(
'Encryption settings'
);
$this
->
attributesInfo
[
'flags'
][
'name'
]
=
_
(
'Encryption settings'
);
...
...
This diff is collapsed.
Click to expand it.
fai/admin/fai/class_faiPartitionTable.inc
+
5
−
4
View file @
0461d118
...
@@ -80,10 +80,11 @@ class PartitionTableAttribute extends DialogOrderedArrayAttribute
...
@@ -80,10 +80,11 @@ class PartitionTableAttribute extends DialogOrderedArrayAttribute
protected
$dialogClass
=
'DiskEntryDialog'
;
protected
$dialogClass
=
'DiskEntryDialog'
;
protected
$partitionAttributes
=
array
(
protected
$partitionAttributes
=
array
(
'cn'
,
'description'
,
'cn'
,
'description'
,
'FAIpartitionNr'
,
'FAIpartitionSize'
,
'FAImountPoint'
,
'FAIpartitionNr'
,
'FAIpartitionSize'
,
'FAIfsType'
,
'FAIpartitionType'
,
'FAImountOptions'
,
'FAIpartitionType'
,
'FAIpartitionFlags'
,
'FAIfsOptions'
,
'FAIpartitionFlags'
,
'FAIfsCreateOptions'
,
'FAImountPoint'
,
'FAImountOptions'
,
'FAIfsTuneOptions'
,
'FAIfsOptions'
,
'FAIpartitionFlags'
,
'FAIfsType'
,
'FAIfsCreateOptions'
,
'FAIfsTuneOptions'
,
'FAIlvmDevice'
'FAIlvmDevice'
);
);
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment
Menu
Explore
Projects
Groups
Topics
Snippets