Commit Graph

150 Commits

Author SHA1 Message Date
asif d0b2c781bf feat(logger): Update test cases
Update JSON and JOURNALD tests to match text tests and use new functions.
2026-07-22 23:48:16 -06:00
asif c4d28d1f8c fix(logger): Fix default subst
Default parameter substitution in all functions was incorrect.
2026-07-22 23:44:08 -06:00
asif f085838781 feat(logger): Add test with operation, error code 2026-07-22 23:42:52 -06:00
asif 4a6c339a07 fix(logger): Fix default subst
Default variable substitution in plain-text function was incorrect.
2026-07-22 23:42:33 -06:00
asif c94f12e976 fix(logger): Fix error in uppercase func
'upper' and 'lower' translate strings were not supplied separately.
2026-07-22 23:38:45 -06:00
asif 5443612381 feat(logger): Add plain-text test output 2026-07-22 23:35:08 -06:00
asif df144a5211 fix(logger): Remove errant 'fi' statements
Remove 'fi' statements left over from previous logic checks.
2026-07-22 23:33:49 -06:00
asif 04811805c3 feat(logger): Remove unused global vars 2026-07-22 23:25:28 -06:00
asif aa446c00e6 feat(logger): Update journal logging function
Use new standardized format fields.
2026-07-22 23:24:52 -06:00
asif 56a5ad59fe refactor(logger): Rename writeJournalLog function
Rename from 'writeJournalLog' to 'writeJournalDLog' for specificity.
2026-07-22 23:19:51 -06:00
asif ce1ab86d22 fix(logger): Fix JSON logger
Level and status were swapped. JSON output was missing new prefix information (timestamp, hostname, etc.)
2026-07-22 23:18:36 -06:00
asif cae57ccf6b feat(logger): Use standardized log levels for JSON 2026-07-22 23:15:44 -06:00
asif 0fcd0d9c13 refactor(logger): Use standardized log levels for plain-text 2026-07-22 23:15:11 -06:00
asif e411a35b93 feat(logger): Add log level translator functions 2026-07-22 23:13:58 -06:00
asif 0e787be456 feat(logger): Add lowercase function 2026-07-22 23:06:34 -06:00
asif 17c33d237f fix(logger): Ensure plain-text status is uppercase 2026-07-22 22:54:25 -06:00
asif 5b55ac95a3 feat(logger): Update JSON logger
Require message, level, and status. Reorganize JSON output to mirror modified syslog-style structure.
2026-07-22 22:53:38 -06:00
asif f4dc8f44b1 feat(logger): Handle plain-text insufficient information
Return without logging if message, level and/or status is not supplied.
2026-07-22 22:49:13 -06:00
asif 3792881529 feature(logger): Add plain-text logger function 2026-07-22 22:42:49 -06:00
asif c1f54a619c refactor(logger): Use ISO8601 timestamp 2026-07-22 21:52:53 -06:00
asif 4c997a6b7d feature [logger] add status logging param 2026-07-22 18:34:14 -06:00
asif 1824d9f139 feat(logger): Framework test file 2026-07-22 17:33:46 -06:00
asif 50b4cf105f chore(ide): Update IDE settings 2026-07-22 17:33:36 -06:00
asif 1e3b545a23 chore(ide): JetBrains IDE configuration files 2026-07-19 23:37:13 -06:00
asif 380509c966 chore(git): Update git control files 2026-07-19 23:36:58 -06:00
asif 71da487aa8 style(fmt): Reformat shell script 2026-07-19 23:33:56 -06:00
asif 3be6eaee0c [preflight] Add check for logger dependency
'logger' is required to facilitate logging to the journaling system.
2026-07-19 18:52:34 -06:00
asif 5c6c8ec4ea [params] Create journal logging switch
Create boolean variable to store journal logging preference.
Set to 'false' by default. Add parameter to activate this preference.
Update help to include this new parameter.
2026-07-19 18:49:34 -06:00
asif c7297a512c [version] Update version, modified date 2026-07-19 15:44:40 -06:00
Asif Bacchus fddb406717 fix error in hyperlink 2.2 2021-05-10 03:22:22 -06:00
Asif Bacchus 4ec190af47 update readme 2021-05-10 03:18:49 -06:00
Asif Bacchus 57ce2d1ac3 fixed headings so TOC links work 2021-05-10 03:09:30 -06:00
Asif Bacchus 1ffd374a4f fix: set TERM for tput if not set
- stop warning messages in syslog from systemd invocation
2021-05-10 02:55:16 -06:00
Asif Bacchus 0cd84a3711 update logwatch readme 2.1 2021-05-09 23:43:41 -06:00
Asif Bacchus d8fe395a19 update readme files 2021-05-09 14:39:28 -06:00
Asif Bacchus ac4cf940ff refactor(SAMPLE): remove un-needed email address 2021-05-09 10:44:21 -06:00
Asif Bacchus dc13e1d412 refactor(LOGWATCH): use new log tags
- update to reference new log tags
- adjust count to separate tally messages
- add CF-ERR tag reports
- re-add level 5 reporting detail
2021-05-09 10:43:05 -06:00
Asif Bacchus e344b027f9 refactor: remove err label on code 99 2021-05-09 10:28:17 -06:00
Asif Bacchus 8801e55e30 style: fix typo, invalid hosts warning summary 2021-05-09 10:24:15 -06:00
Asif Bacchus b05192a613 fix: wrong pipeline variable ref in writelog 2021-05-09 09:49:47 -06:00
Asif Bacchus d796bf6f63 fix: wrong variable referenced for list to update 2021-05-09 09:47:41 -06:00
Asif Bacchus db8a615d36 refactor: use function to write to log
- much more consistent
- one place to change all entries
2021-05-09 09:46:15 -06:00
Asif Bacchus 31eb503245 style: change 'domain' to 'host'
terminology is more correct and less potentially confusing
2021-05-09 08:48:56 -06:00
Asif Bacchus 3f9d164285 style: rename functions to clear spellcheck 2021-05-09 08:45:24 -06:00
Asif Bacchus 39f5445c28 perf: simpler iteration condition checking
- less complex conditions
- easier code to understand
- cleans up extraneous delimiters
- skips null entries immediately
2021-05-09 08:44:47 -06:00
Asif Bacchus 220263c1f9 refactor: change log tags
- separate tags for summary vs individual messages for accurate logwatch
 counting
- update code 99 exit to match other errors
- change CF error tags to match new format
2021-05-09 07:08:44 -06:00
Asif Bacchus fe0f9caef1 feature: process multiple CF API errors
- handle multiple CF API errors properly by grouping and reporting
- update error messages
- unify CF error tags in log to CF-ERROR
2021-05-09 06:49:49 -06:00
Asif Bacchus d9600c822f style: alphabetize functions 2021-05-09 06:39:55 -06:00
Asif Bacchus 5569bbc535 refactor: remove cfEmail
- authorized email not required by CF when using bearer token
2021-05-09 04:35:46 -06:00
Asif Bacchus f4f3c89e5e refactor: reduce nesting, update err codes
- detect curl vs CF API errors separately
- error 25 changed to error 3 (curl/network)
- error 25 reservedfor CF API errors
- add CF error messages to all err 25s
- change error 98 (updates) to error 26
- remove error code for exit with warning
- add CF error messages on update failures
- drastically reduce if/else nesting
2021-05-09 04:33:41 -06:00