HostOSConfigurationModules¶
TechPreview since 2.26.0 (17.1.0 and 16.1.0)
Warning
For security reasons and to ensure safe and reliable cluster operability, test this configuration on a staging environment before applying it to production. For any questions, contact Mirantis support.
This section describes the HostOSConfigurationModules
custom resource (CR)
used in the Container Cloud API. It contains all necessary information to
introduce and load modules for further configuration of the host operating
system of the related Machine
object. For description of module format,
schemas, and rules, see Format and structure of a module package.
Note
This object must be created and managed on the management cluster.
For demonstration purposes, we split the Container Cloud
HostOSConfigurationModules
CR into the following sections:
HostOSConfigurationModules metadata¶
metadata¶
The Container Cloud HostOSConfigurationModules
custom resource (CR) contains the following
fields:
apiVersion
Object API version that is
kaas.mirantis.com/v1alpha1
.
kind
Object type that is
HostOSConfigurationModules
.
The metadata
object field of the HostOSConfigurationModules
resource contains
the following fields:
name
Object name.
Configuration example:
apiVersion: kaas.mirantis.com/v1alpha1
kind: HostOSConfigurationModules
metadata:
name: host-os-configuration-modules-sample
HostOSConfigurationModules configuration¶
The spec
object field contains configuration for a
HostOSConfigurationModules
object and has the following fields:
modules
List of available modules to use as a configuration. Each entry has the following fields:
name
Required. Module name that must equal the corresponding custom module name defined in the
metadata
section of the corresponding module. For reference, see MOSK documentation: Day-2 operations - Metadata file format.
url
Required for custom modules. URL to the archive containing the module package in the FQDN format. If omitted, the module is considered as the one provided and validated by Container Cloud.
version
Required. Module version in SemVer format that must equal the corresponding custom module version defined in the
metadata
section of the corresponding module. For reference, see MOSK documentation: Day-2 operations - Metadata file format.
sha256sum
Required. Hash sum computed using the SHA-256 algorithm. The hash sum is automatically validated upon fetching the module package, the module does not load if the hash sum is invalid.
deprecates
Since 2.28.0 (17.3.0 and 16.3.0)Reserved. List of modules that will be deprecated by the module. This field is overriden by the same field, if any, of the module
metadata
section.Contains the
name
andversion
fields specifying one or more modules to be deprecated. Ifname
is omitted, it inherits the name of the current module.
Configuration example:
spec:
modules:
- name: mirantis-provided-module-name
sha256sum: ff3c426d5a2663b544acea74e583d91cc2e292913fc8ac464c7d52a3182ec146
version: 1.0.0
- name: custom-module-name
url: https://fully.qualified.domain.name/to/module/archive/module-name-1.0.0.tgz
sha256sum: 258ccafac1570de7b7829bde108fa9ee71b469358dbbdd0215a081f8acbb63ba
version: 1.0.0
HostOSConfigurationModules status¶
The status
field of the HostOSConfigurationModules
object contains the
current state of the object:
modules
List of module statuses, indicating the loading results of each module. Each entry has the following fields:
name
Name of the loaded module.
version
Version of the loaded module.
url
URL to the archive containing the loaded module package in the FQDN format.
docURL
URL to the loaded module documentation if it was initially present in the module package.
description
Description of the loaded module if it was initially present in the module package.
sha256sum
Actual SHA-256 hash sum of the loaded module.
valuesValidationSchema
JSON schema used against the module configuration values if it was initially present in the module package. The value is encoded in the
gzip+base64
format.
state
Actual availability state of the module. Possible values are:
available
orerror
.
error
Error, if any, that occurred during the module fetching and verification.
playbookName
Name of the module package playbook.
deprecates
Since 2.28.0 (17.3.0 and 16.3.0)List of modules that are deprecated by the module. Contains the
name
andversion
fields specifying one or more modules deprecated by the current module.
deprecatedBy
Since 2.28.0 (17.3.0 and 16.3.0)List of modules that deprecate the current module. Contains the
name
andversion
fields specifying one or more modules that deprecate the current module.
supportedDistributions
Since 2.28.0 (17.3.0 and 16.3.0)List of operating system distributions that are supported by the current module. An empty list means support of any distribution by the current module.
HostOSConfigurationModules
status example:
status:
modules:
- description: Brief description of the module
docURL: https://docs.mirantis.com
name: mirantis-provided-module-name
playbookName: directory/main.yaml
sha256sum: ff3c426d5a2663b544acea74e583d91cc2e292913fc8ac464c7d52a3182ec146
state: available
url: https://example.mirantis.com/path/to/module-name-1.0.0.tgz
valuesValidationSchema: <gzip+base64 encoded data>
version: 1.0.0
deprecates:
- name: custom-module-name
version: 1.0.0
- description: Brief description of the module
docURL: https://example.documentation.page/module-name
name: custom-module-name
playbookName: directory/main.yaml
sha256sum: 258ccafac1570de7b7829bde108fa9ee71b469358dbbdd0215a081f8acbb63ba
state: available
url: https://fully.qualified.domain.name/to/module/archive/module-name-1.0.0.tgz
version: 1.0.0
deprecatedBy:
- name: mirantis-provided-module-name
version: 1.0.0
supportedDistributions:
- ubuntu/jammy