Commit graph

1676 commits

Author SHA1 Message Date
Lord Hepipud
c82ab620bc Fixes unhanded true output during installation 2022-01-28 09:01:38 +01:00
Lord Hepipud
f4e58c2005
Merge pull request #444 from Icinga:fix/get-icingaservices_returns_unknown_on_wildcard
Fix: Get-IcingaServices returns unknown for StartType on wildcards

Fixes `Get\-IcingaServices` which returned `Unknown` for service `StartType`, in case the `-Service` argument contained values with wildcard `*`.

Example:

```powershell
$result = (Get-IcingaServices -Service 'icinga*');
$result.values.configuration.starttype;
$result.values.metadata.DisplayName

Name                           Value
----                           -----
value                          Unknown
raw                            5
value                          Unknown
raw                            5
Icinga PowerShell Service
Icinga 2
```

Fixes #443
2022-01-27 22:06:33 +01:00
Lord Hepipud
c96d49551e Fixes Get-IcingaService StartType with wildcards 2022-01-27 22:05:32 +01:00
Lord Hepipud
c8e8683390
Merge pull request #451 from Icinga:fix/jea_error_on_no_modules_and_output
Fix: JEA context cannot be created and command not found output

Fixes the PowerShell not being able to enter the JEA context, if only the Icinga PowerShell Framework is installed and no other component like plugins being present.

Fixes in addition the output for the JEA PowerShell, in case a check command cannot be executed. Previously the pipe `|` for performance data was always added, which is now gone.
2022-01-27 21:59:56 +01:00
Lord Hepipud
210862e683 Fixes JEA error on no modules installed and output 2022-01-27 21:59:38 +01:00
Lord Hepipud
9bcd2210e7
Merge pull request #450 from Icinga:feature/improve_show_commands
Feature: Improve show commands and extend Show-Icinga

Improves show command `Show-IcingaRegisteredServiceChecks` to use new layout for displaying information and adds new command `Show-IcingaRegisteredBackgroundDaemons`, following the same layout and possiblity.

In addition extends `Show-Icinga` by both commands and adds debug and api forwarder features to environment list.
2022-01-27 21:06:54 +01:00
Lord Hepipud
586b55adc0 Improves show commands and extends Show-Icinga 2022-01-27 21:06:13 +01:00
Lord Hepipud
72995178e4
Merge pull request #449 from Icinga:fix/exception_handling_module_import_installation
Fix: Error handling for failed module import

Adds improved exception handling for using `Install\-IcingaComponent` while importing of modules failed, because of missing dependencies for example.
2022-01-27 19:54:13 +01:00
Lord Hepipud
3eac2b3080 Fixes error handling for failed module import 2022-01-27 19:53:10 +01:00
Lord Hepipud
335038c957
Merge pull request #448 from Icinga:feature/secure_array_sorting_external_modules
Feature: Adds support to sort arrays without ScriptBlocks

Adds a new function, allowing to sort arrays with objects inside for specific members wihtout having to use ScriptBlocks on external modules.

This allows a secure usage even in JEA context and external modules are not blocked by calling `ScriptBlocks`
2022-01-27 19:39:10 +01:00
Lord Hepipud
71269705cf Adds feature to sort arrays without ScriptBlocks 2022-01-27 19:37:40 +01:00
Lord Hepipud
d525b22cc1
Merge pull request #447 from Icinga:feature/surpress_errors_on_new_progress_status
Feature: Supresses error messages on progress status

Adds `-PrintErrors` to `New-IcingaProgressStatus`, surpressing all errors by default, allowing to add this for testing internally.
2022-01-27 16:26:16 +01:00
Lord Hepipud
df9f3c890e Supresses error messages on progress status 2022-01-27 16:23:17 +01:00
Lord Hepipud
a3c0fa0da9
Merge pull request #446 from Icinga:fix/progress_status_rework
Fix: Reworks progress preference to remove ui glitches

Reworked Icinga for Windows progress status writer, which now properly closes progress status windows and allows to force close them afterwards, fixing previous UI glitches.
2022-01-27 15:35:39 +01:00
Lord Hepipud
cf52e6372e Fixes progress status writer by reworking 2022-01-27 15:34:17 +01:00
Lord Hepipud
ce67756910
Merge pull request #445 from Icinga:feature/repair_icinga_agent_service_command
Feature: Adds command to repair Icinga Agent service

In some cases it can happen, that during an upgrade of the Icinga Agent, the service fails because on how the .msi installer works.

This adds a new Cmdlet `Repair-IcingaService`, which resolves the problem and repairs the service.
2022-01-27 13:38:14 +01:00
Lord Hepipud
b97aca7d25 Adds command to repair Icinga Agent service 2022-01-27 13:37:13 +01:00
Lord Hepipud
269927cb6e
Merge pull request #442 from Icinga:fix/use_icinga_might_cause_exception
Fix: Exception on Use-Icinga

In some cases it can happen, that Icinga for Windows throws an exception while using \\\`Use\\\-Icinga\\\`. This happens because of an internal handling for rebuilding the cache, which tried to re\\\-import the modules.

This code seems no longer to be required and causes only problems while trying to use \\\`Use\\\-Icinga\\\` while inside the same shell, that Icinga for Windows is being installed the first time in.

As this seems no longer to be required, we will remove this code.
2022-01-26 16:24:23 +01:00
Lord Hepipud
293d5c06fa Fixes possible exception on Use-Icinga 2022-01-26 16:23:38 +01:00
Lord Hepipud
318f8c5ac0 Fixes doc spelling errors 2022-01-26 15:05:13 +01:00
Lord Hepipud
97bd4448a8
Merge pull request #441 from Icinga:fix/exception_on_framework_loading
Fix: Exception on loading by missing environment

Fixes an exception while loading the Framework, caused by a race condition for missing environment variables which are accessed by some plugins before the Framework is loaded properly.
2022-01-25 12:19:42 +01:00
Lord Hepipud
7faa516c15 Fixes exception on loading by missing environment 2022-01-25 12:18:08 +01:00
Lord Hepipud
db4d86e5b5
Merge pull request #440 from Icinga:feature/add_service_upgrade_notification
Feature: Adds upgrade notification to service binary

Ensures we add an upgrade notification if we are running the Icinga for Windows Service binary older than v1.2.0, which will not work with Icinga for Windows v1.8.0 or later.
2022-01-25 11:55:23 +01:00
Lord Hepipud
fe000c020f Adds upgrade notification to service binary 2022-01-25 11:54:18 +01:00
Lord Hepipud
a47af1e60a Updates docs 2022-01-25 11:28:33 +01:00
Lord Hepipud
45d189756e
Merge pull request #439 from Icinga:fix/move_performance_counter_to_private
Fix: Moves PerformanceCounter to private space

Moves PerformanceCounter to private space from previous public, which caused some problems.
2022-01-25 11:27:33 +01:00
Lord Hepipud
f6cf9492e5 Moves PerformanceCounter to private space 2022-01-25 11:26:51 +01:00
Lord Hepipud
c600a0fc68
Merge pull request #414 from Icinga:fix/rewrite_service_check_daemon
Fix: Rewrite Icinga for Windows service check daemon

Rewrite Icinga for Windows service check daemon for collecting metrics over time, to improve performance, decrease required resources and fix memory leaks.
2022-01-25 10:01:27 +01:00
Lord Hepipud
a23a40b23f Rewrite IfW service check daemon 2022-01-25 10:00:19 +01:00
Lord Hepipud
28f9f2777e
Merge pull request #438 from Icinga:feature/add_restapi_feature_to_imc
Feature: Adds Rest-Api check forwarder to IMC wizard

Adds the support for enabling the Rest\-Api including the Api\-Check by running the IMC installation.
2022-01-24 15:16:50 +01:00
Lord Hepipud
4d4d9caf2e Adds feature to enable Api-Checks over IMC install 2022-01-24 15:16:23 +01:00
Lord Hepipud
c88897e476
Merge pull request #436 from Icinga:fix/plugin_docs_generator_lookup
Fix: Plugin Doc generator file lookup

Fixes a lookup error for existing plugin documentation files, which caused files not being generated properly in case a similar name was already present on the system.
2022-01-23 13:12:00 +01:00
Lord Hepipud
2b61c297ea Fixes plugin doc generator file lookup 2022-01-23 13:11:21 +01:00
Lord Hepipud
3313976670
Merge pull request #428 from Icinga:feature/move_eventlog_from_application
Feature: Moves EventLog out of Application log for IfW

We will move the Icinga for Windows EventLog away from the current \`Application\` log and move it into a custom \`Icinga for Windows\` log, to ensure the \`Application\` log is not spammed with Icinga for Windows events.
2022-01-21 18:42:45 +01:00
Lord Hepipud
8244c2d440 Moves IfW EventLog out of Application log 2022-01-21 18:40:32 +01:00
Lord Hepipud
ba5517e13f
Merge pull request #434 from Icinga:fix/exception_inside_ise_session
Fix: Exception and freezes inside PowerShell ISE session

Fixes Icinga for Windows exception while running \`icinga\` commands or the Icinga Mangement Console inside an \`PowerShell ISE\` session, which behaves differently.

Instead, we now load Icinga for Windows and inform the user about limitations properly.
2022-01-20 18:17:53 +01:00
Lord Hepipud
43fd685126 Fixes exceptions and freezes inside ISE session 2022-01-20 18:15:08 +01:00
Lord Hepipud
b81a757701
Merge pull request #433 from Icinga/feature/update_gitignore
Feature: Updates .gitignore for Visual Studio
2022-01-16 00:19:50 +01:00
Lord Hepipud
cec2c1e732 Updates .gitignore for Visual Studio 2022-01-16 00:19:01 +01:00
Lord Hepipud
1316ddbb3a
Merge pull request #431 from Icinga:fix/code_styling_naming_scriptanalyzer
Fix: Code styling, spelling errors and PSScriptAnalyzer

Fixes lots of code styling, spelling and script analyzer issues.

Disabling UseConsistentIndentation because it is not properly working for multi\-line commands with arguments and array/hashtable objects.
2022-01-14 22:31:21 +01:00
Lord Hepipud
4ef55bddb4 Fixes lots of code styling, spelling and script analyzer
Disabling UseConsistentIndentation because it is not
properly working for multi-line commands with arguments
and array/hashtable objects
2022-01-14 22:26:53 +01:00
Lord Hepipud
ac7aad5e07
Merge pull request #430 from Icinga:fix/remove_restapi_warnings_and_experimental
Fix: Removes experimental for API Checks and module requirements

Fixes experimental state of \`API Check\` feature by removing that term and removing the requirement to install \`icinga\-powershell\-restapi\` and \`icinga\-powershell\-apichecks\`
2022-01-14 20:54:46 +01:00
Lord Hepipud
dd2d71ee07 Remove experimental for API Checks and module note 2022-01-14 20:53:16 +01:00
Lord Hepipud
bf8d6479a9
Merge pull request #419 from Icinga:fix/managed_user_lookup_time
Fix: Icinga Managed User lookup time

Fixes the lookup time if a user is managed by Icinga for Windows or not in large Active Directory environments, by using \`Get\-LocalUser\` instead.

This Cmdlet is available starting with PowerShell 5.0 and later and only required in general for running Icinga for Windows in JEA context. As JEA is only supported starting with PowerShell 5.0 or later, this will not cause any problems.

In case the command is executed on an older system without the \`Get\-LocalUser\` Cmdlet available, Icinga for Windows will handle all users tested with the new implementation as \`not\` managed by Icinga for Windows.
2022-01-14 20:00:57 +01:00
Lord Hepipud
7c019e7cd2
Merge pull request #426 from Icinga:feature/add_detailed_exception_report_feature
Feature: Adds exception report

Adds a new feature to EventLog writer, allowing to parse an exception report to identity the exact root cause and location, on where the error occurred in first place.
2022-01-13 00:04:14 +01:00
Lord Hepipud
008b4920f1 Adds exeception detail reporting 2022-01-13 00:03:10 +01:00
Lord Hepipud
45b832ac3d
Merge pull request #425 from Icinga:feature/allow_force_cert_creation_over_imc
Feature: Allow Force-Creation of certificates for Agent over IMC

Adds support to re\-create the Icinga Agent certificates, even when they are already present on the system. This will resolve the manual requirement to delete the folder or certificates, in case the Icinga CA changes for example
2022-01-04 21:55:51 +01:00
Lord Hepipud
46bcb914fc Adds support for cert force creation over IMC 2022-01-04 21:53:28 +01:00
Lord Hepipud
94d09c6b43
Merge pull request #424 from Icinga:fix/repository_sync_can_cause_invalid_json_exception
Fix: Sync-IcingaRepository can cause invalid JSON primitive

By using the \`Sync\-IcingaRepository\` function, it might happen that in case the parent site is returning a file listing instead of an error page, the downloaded \*\*repository\*\* file is only the list of the files and not the proper JSON repo file.

Instead we now check the result properly and fallback by adding \`ifw.repo.json\` as it was intended before.
2022-01-04 20:56:36 +01:00
Lord Hepipud
55a0ce4987 Fixes repo sync by properly checking result 2022-01-04 20:55:34 +01:00