Skip to content

Instantly share code, notes, and snippets.

@pauloconnor
Last active December 1, 2022 09:33
Show Gist options
  • Star 32 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pauloconnor/4707710 to your computer and use it in GitHub Desktop.
Save pauloconnor/4707710 to your computer and use it in GitHub Desktop.
Logstash Mutate Filter for stripping Linux color codes from log files
# Get rid of color codes
mutate {
gsub => ["message", "\x1B\[([0-9]{1,2}(;[0-9]{1,2})?)?[m|K]", ""]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment