package_install_version_cmp
Install a package or verify if it is installed in a specific version, or higher or lower version than a version specified.
⚙️ Compatible targets: Linux
⚠️ Deprecated: This method is deprecated and should not be used.
Parameters
Name | Documentation |
---|---|
name | Name of the package to install or verify. This parameter is required. |
version_comparator | Comparator between installed version and defined version, can be ==,<=,>=,<,>,!=. Choices:
This parameter is required. |
package_version | The version of the package to verify (can be "latest" for latest version). This parameter is required. |
action | Action to perform, can be add, verify (defaults to verify). This parameter is required. |
Outcome conditions
You need to replace ${name}
with its actual canonified value.
- ✅ Ok:
package_install_${name}_ok
- ☑️ Already compliant:
package_install_${name}_kept
- 🟨 Repaired:
package_install_${name}_repaired
- ☑️ Already compliant:
- ❌ Error:
package_install_${name}_error
Example
method: package_install_version_cmp
params:
name: VALUE
version_comparator: ==
action: VALUE
package_version: VALUE
Documentation
Example:
methods:
"any" usebundle => package_install_version_cmp("postgresql", ">=", "9.1", "verify");