This silences error messages when:
- There is no eventer in the context.Context
- There is no SysEventer
- And a new env var is set
Previously when the first two conditions where met, the error was logged
to a default hclog.Logger with the error being wrapped in a message to
note the lack of an eventer. In production this is a very important
message to help operators fix a likely misconfiguration. However, in
tests it is common to not have an eventer setup, meaning this generates
a lot of noise. This uses the CI environment variable which is an
environment variable set by most common CI environments. Developers can
set this variable locally to reduce the log noise:
export CI=true
See:
https://docs.github.com/en/actions/learn-github-actions/environment-variables#default-environment-variables
https://circleci.com/docs/2.0/env-vars/#built-in-environment-variables
https://docs.travis-ci.com/user/environment-variables/#default-environment-variables