Closed sbryant closed 6 years ago
Small update, I've updated the CI to use 1.8.x, 1.10.x and tip. The consul testutils
package requires an updated testing
package. The travis CI setup will now download a consul binary and use that for the integration tests.
@sbryant Merged, thanks for your contribution and hard work!
I'm using
consul-cli
to register services and wanted to add some headers to the http checks. The current solution was to use--raw
and throw some json at it:Rather tossing JSON around it would be nice to add
--header "Header: Val"
flag support.This PR adds
stringSlice
support to themapValue
Value implementation. Currently the string slice is serializes to CSV to work the existing implementation.Added the ability turn off CSV reading when setting up a
stringSliceValue
.With those out of the way the header flag implementation is pretty straight forward. The flag can be specified multiple times. These headers will be parsed and passed along as to the
onsulapi.AgentServiceCheck
structs.Added some command tests to make it easier to verify the implementation.