Fix: Clear-Host throwing exceptions during automation tasks
Fixes an issue with `Clear-Host` which could cause an exception during certain automation tasks, causing it to fail
Feature: Adds new feature to write documents easier
Adds new feature to write document content easier by storing it in memory first and then allowing to write it to disk at once with proper UTF8 encoding
New cmdlets:
* New-IcingaDocumentObject
* Add-IcingaDocumentContent
* Write-IcingaDocumentFile
Useful in case someone renames the commands in Director.
Otherwise, in this case, all commands would be broken with ifw-api as vars.ifw_api_command defaults to $command.name$.
Fix: Sync-IcingaRepository not saving SSH settings
Fixes `Sync-IcingaRepository` which did not save the SSH user and host inside the repository configuration, preventing `Update-IcingaRepository` to work properly and added missing scp progress
Fix: Config generator custom variable too long error message
Fixes error message during config generation with `Get-IcingaCheckCommandConfig` to make it more clear, in case the custom variables generated are too long for the Icinga Director import
Feature: Adds support to write the name of the repo inside the json file
Adds support to write the name of the repository synced/created into the local `ifw.repo.json` file
Feature: Adds support to not load a new PowerShell instance for command icinga
Adds support to run command `icinga` with new argument `-NoNewInstance`, to use `-RebuildCache` as example to update the current PowerShell instance with all applied changes, instead of create a new shell instance.
Does not support the argument `-DeveloperMode` in the same call, as Icinga for Window is dependent on these files for the current session.
Fix: Improves REST-Api memory management
Fixes some memory management while using the REST-Api to clear connection objects once they are no longer required
Get-IcingaCheckCommandConfig: provide vars.ifw_api_arguments in each command
Adds support for Icinga 2.14.0 native Icinga for Windows API communication
Fix: Error and exception handling over API checks
Fixes error and exception handling while using API-Checks, which now will in most cases always return a proper check-result object and also abort while running into plugin execution errors, in case a server is not reachable by the time sync plugin as example.
Feature: Adds support for -RebuildCache flag on icinga cmd to rebuild component cache
Adds support to simply use `-RebuildCache` for
```powershell
icinga -RebuildCache;
```
or
```powershell
icinga -Shell -RebuildCache;
```
to generate a new cache file not only for the Framework (like before), but also for all installed components of Icinga for Windows.
This makes it easier for regular use and error handling, as users will not have to remember a different Cmdlet or use the `-DeveloperMode` to force Icinga for Windows to rebuild everything.
Feature: Adds support to configure Director Self-Service config string
This new feature allows to configure the Icinga Director Self-Service call during registration, by modifing the JSON-String. This will only apply to the first time registration of a host and is not modified again, unless the host and director keys for this specific host object are removed.
This works directly inside the IMC installation wizard as well as for the exported installation command or file.
By doing so, you can manually define the IP-Address with `address` key in your JSON as well as the display name of an object with `display_name`. Example:
```json
{ "address": "127.0.0.1", "display_name": "Example Host" }
```
The following constants are available inside the configuration:
`$ifw.hostaddress$`: Will use the default IP-Address automatically fetched from the system
`$ifw.hostname$`: The current hostname of the host, without FQDN and not modiying upper/lowercase
`$ifw.hostfqdn$`: The current FQDN of the host, without case modification
For lower and upper case modification, you can use `.tolower` or `.toupper` for the hostname and FQDN, example:
```json
{ "address": "127.0.0.1", "display_name": "$ifw.hostname.tolower$" }
```
Feature: Adds support to ignore SSL errors on IMC, Shell and Installer
Adds support to set the flag `-NoSSLValidation` for Cmdlets `icinga` and `Install-Icinga`, to ignore errors on self-signed certificates within the environment.
Example:
```powershell
icinga -NoSSLValidation
```
Icinga Shell:
```powershell
icinga -Shell -NoSSLValidation
```
Feature: Adds support to allow Agent cipher list configuration
Adds support for `Write-IcingaAgentApiConfig` function to configure the Icinga Agent TLS cipher list setting.
to properly support just importing the ifw-api command.
That command e.g. takes DSL/JSON arrays [], not PS ones @(). Similar with strings.
Therefore set vars.ifw_api_arguments as ifw-api expects.