* add a TLS parameter for cacert
* pass a ca cert into http request
* test preflight
* make schemas
* log extra information from http request
* pass a proxy into the collector spec
* hitting a segfault; breakpoint
* accept a dir, file, or a string-literal as CA
* move tls params into get, put, post methods
* test for cert untrusted response
* make generate
* make schemas
* more test cases
* make schemas
* dont include system certs
* make generate && make schemas
* resolve gosec G402 warning
* remove old check for system certs
* ignore errcheck "return value not checked" linter errors
* feat: Install goldpinger if one does not exist when running goldpinger collector
- Deploy golpinger daemonset if one is not detected in the cluster
- Clean up all deployed resources
- Add delay to allow users to wait for goldpinger to perform checks
Signed-off-by: Evans Mungai <evans@replicated.com>
* Add missing test data file
Signed-off-by: Evans Mungai <evans@replicated.com>
* Better naming of create resource functions
Signed-off-by: Evans Mungai <evans@replicated.com>
---------
Signed-off-by: Evans Mungai <evans@replicated.com>
* feat: goldpinger analyser
Analyser to generate a report from goldpinger results
* Add goldpinger testdata
* Goldpinger collector
* Improvements after running tests
* More minor updates after further testing
* Better error message if a container fails to start
* A few more updates
* Add goldpinger e2e test
* Update schemas
* Clean up help installs in e2e tests
* Add resource limits to goldpinger pods
* Some minor improvements
* Some more changes noted when writing docs
* Update schemas
* A few more updates when testing with kURL
* Log goldpinger tests
* Tests before exit code
* Add dry-run flag
* No traces on dry run
* More refactoring
* More updates to support bundle binary
* More refactoring changes
* Different approach of loading specs from URIs
* Self review
* More changes after review and testing
* fix how we parse oci image uri
* Remove unnecessary comment
* Add missing file
* Fix failing tests
* Better error check for no collectors
* Add default collectors when parsing support bundle specs
* Add missed test fixture
* Download specs with correct headers
* Fix typo
* stashing changes
* split filesystem collector into fio and legacy functions
* read fio results into analyzer
* remove test script
* update go.mod
* remove old notes
* go mod tidy
* fix up go.mod
* fix up go.mod
* refactor tests for fio
* make schemas
* remove local scripts
* local watch script for building troubleshoot
* document watch script
* fix var names
* handle errors if run as non-root
* go mod tidy
* use String interface
* collector happy path test
* invalid filesize
* invalid filesize
* tests
* remove old code
* remove old init function
* let actions tests run this
* clean up tests
* go mod tidy
* remove duplicated type declaration
* remove old file create code
* feat: Add Strict flag to LoadSpecs API
Strict flag which can be used to toggle between true
(raising errors if a document is invalid)
and false (ignoring invalid documents, perhaps logging a warning).
* Granular error handling multidocs in secrets and configmaps
* Fix failing test
* feat: add loader APIs to load specs from a list of yaml docs
The change introduces a loader package that will contain loader
public APIs. The aim of these APIs will be to, given any source of
troubleshoot specs, the loaders will fetch the specs and parse out
all troubleshoot objects that can be extracted.
* Some refactoring
* Some more changes
* More changes caught when testing vendor portal
* Add tests and rename Troubleshoot kinds struct
* Additional test
* Handle ConfigMap and Secrets with multiple specs in them
* Fix failing test
* Revert multidoc split implementation
* Fix merge conflict
* Change LoadFromXXX functions to a single LoadSpecs function
* we can now read preflight specs out of secrets, either from stdin or file input
* moved spec read logic out into its own function so it can be unit
tested easier
* added more comprehensive unit testing on the different ways we can read in specs
* adding test coverage for preflight.RunPreflights()
TDD to work on https://github.com/replicatedhq/troubleshoot/issues/906
and verify the fix is successful
* go.mod/go.sum: removing gnomock stuff since it's not in use (yet)
* Makefile: try running the preflight integration test with the e2e tests,
since there's a K3s instance in place already
* Makefile add a dedicated test-integration task, which runs as it's own
github action job
* Makefile: exclude a few things from test-integration that break the
github action job
* WIP on preflight tests, addressing some of @banjoh's feedback, more to
go though (specifically changing over to using assert)
* preflight tests: use the testify libraries, restructure code to be
formatted more like other tests in this project
* feat(redactors): Run redactors on an existing support bundle
Add redact subcommand to support-bundle to allow running redactors on an
existing bundle to creating a new redacted bundle.
The command will be launched like so
support-bundle redact <redactor urls> --bundle support-bundle.tar.gz
Fixes: #705
feat(collectors): Add mTLS parameters to the redis collector
For a redis collector spec targeting a redis server configured to accept
(m)TLS connections we need to pass in the necessary TLS parameters in order
to successfully connect to the server. Both preflight and support bundle
specs use this collector.
This change allows us to pass in the necessary TLS parameters via inlined
TLS configuration or via a secret reference.
Fixes#746