Commit Graph

752 Commits

Author SHA1 Message Date
Łukasz Mierzwa
2a8e13733c Add CODEOWNERS file
CODEOWNERS allows github to automatically require code review from the right set of people. Start with defaulting to myself for all files
2018-03-09 18:44:54 -08:00
Łukasz Mierzwa
ceb24c6c07 Merge pull request #243 from cloudflare/api_test
Use the correct variable in tests
2018-03-07 11:19:57 -08:00
Łukasz Mierzwa
deebde7b0c Comment out dead condition 2018-03-06 18:42:19 -08:00
Łukasz Mierzwa
d7913c9a80 Use the correct variable in tests
'es.JiraURL == es.JiraURL' is always true, it should compare es with gs. Fix it and reformat for readability
2018-03-06 18:42:19 -08:00
Łukasz Mierzwa
4d5e4c4057 Merge pull request #245 from cloudflare/update-js-deps
Upgrade moment to >=2.19.3
2018-03-06 16:57:40 -08:00
Łukasz Mierzwa
06ee92d255 Upgrade moment to >2.19.3
CVE-2017-18214 affects <2.19.3, fixes #244
2018-03-05 18:47:30 -08:00
Łukasz Mierzwa
4bdb014855 Merge pull request #236 from cloudflare/go1.10
Use Go 1.10
2018-02-17 19:51:02 -08:00
Łukasz Mierzwa
7629813add Use Go 1.10
Use Go 1.10 when testing/releasing on Travis and building docker images
2018-02-16 21:42:14 +00:00
Łukasz Mierzwa
4efd9ea804 Merge pull request #233 from cloudflare/am-0.14.0
Add mock files for Alertmanager 0.14.0
2018-02-16 10:15:59 +00:00
Łukasz Mierzwa
9de77e342d Add mock files for Alertmanager 0.14.0 2018-02-16 09:35:07 +00:00
Łukasz Mierzwa
fddab66ed3 Merge pull request #234 from cloudflare/print-version
Print mock version when testing
2018-02-16 09:34:32 +00:00
Łukasz Mierzwa
48ca69fb7c Enable verbose output from go test 2018-02-13 22:52:56 +00:00
Łukasz Mierzwa
9a5909a4ab Log Alertmanager version used for testing
There's ever growing list of tested Alertmanager releases, print version so it's more obvious what do we actually test against
2018-02-13 22:52:43 +00:00
Łukasz Mierzwa
c601abad56 Merge pull request #230 from cloudflare/legacy-drop
Drop legacy settings
2018-02-01 21:30:30 -08:00
Łukasz Mierzwa
1ff002f979 Update tests to use new envs instead of legacy 2018-02-01 21:09:36 -08:00
Łukasz Mierzwa
94ec8f084f Set proxy value when logging configuration on startup 2018-02-01 21:09:36 -08:00
Łukasz Mierzwa
f6efebb934 Drop legacy settings
Those were left for compatibility and marked as deprecated, remove it for the next release
2018-02-01 21:09:36 -08:00
Łukasz Mierzwa
58077fa0ec Use new envs in Makefile
FILTER_DEFAULT is a legacy env, FILTERS_DEFAULT should be used
2018-02-01 21:09:36 -08:00
Łukasz Mierzwa
396ace2aa3 Merge pull request #231 from cloudflare/dep-prune
dep prune is depracated, drop it
2018-02-01 21:08:38 -08:00
Łukasz Mierzwa
4f5926d54f dep prune is depracated, drop it
dep will now run prune based on the Gopkg.toml settings, add a config for it and drop 'dep prune' from the Makefile
2018-01-31 22:07:30 -08:00
Łukasz Mierzwa
e590305b4a Merge pull request #226 from cloudflare/revert-travis-branch
Revert "Tell Travis CI to only build on pushes to the master branch"
v0.9.1
2018-01-28 22:37:49 -08:00
Łukasz Mierzwa
8a676c2c0a Revert "Tell Travis CI to only build on pushes to the master branch"
This reverts commit 15a8446588.

Limiting build branches to only master has a side effect of not triggering automatic release builds, revert it to Travis defaults since we want release branch jobs.
2018-01-28 22:14:50 -08:00
Łukasz Mierzwa
eabb4a2f46 Merge pull request #212 from cloudflare/bakelite
Use bakelite to cross-compile binaries on Travis
v0.9.0
2018-01-28 21:48:19 -08:00
Łukasz Mierzwa
061ffe3e60 Use bakelite to crosscompile binaries 2018-01-28 20:37:05 -08:00
Łukasz Mierzwa
78cbd104c9 Merge pull request #225 from cloudflare/file-uri-fix
Use decoded URI path partial for file paths
2018-01-27 15:15:48 -08:00
Łukasz Mierzwa
782b633f8c Fix error checking in file read tests 2018-01-27 09:57:19 -08:00
Łukasz Mierzwa
b8cf0a83f4 Correctly handle all types of file:// values
For absolute paths we correctly return full decoded path, but for relative paths we can't simply strip file:// prefix as it might leave query args in place. Build absolute path by joining working dir + hostname part + path part.
Add an extra test case for coverage.
2018-01-27 09:54:19 -08:00
Łukasz Mierzwa
fe1cdc9977 Merge pull request #224 from cloudflare/version
Add --version flag
2018-01-27 09:39:57 -08:00
Łukasz Mierzwa
193c6cf372 Drop duplicated pflag.Parse call 2018-01-26 18:21:57 -08:00
Łukasz Mierzwa
c1a4e30bbd Add --version flag
This is useful to get the version from the compiled binary without the need to run it
2018-01-26 18:21:40 -08:00
Łukasz Mierzwa
b88aa4a1c9 Merge pull request #223 from cloudflare/v04-fix-args
Drop the path from v0.4 query args
2018-01-26 09:26:08 -08:00
Łukasz Mierzwa
ded69c11ff Drop the path from v0.4 query args
This results in requests to 'GET http://localhost:9093/api/v1/silences?api/v1/silences?limit=2147483647' instead of 'GET http://localhost:9093/api/v1/silences?limit=2147483647'. Too much copy&paste.
2018-01-25 19:34:35 -08:00
Łukasz Mierzwa
37364741ac Merge pull request #222 from cloudflare/v04-silences
Allow passing query args to HTTP requests send to the Alertmanager API
2018-01-25 16:01:29 -08:00
Łukasz Mierzwa
0f73b20bc6 Allow passing query args to HTTP requests send to the Alertmanager API
Alertmanager 0.4.x silences endpoint uses pagination, code for this was incorrectly dropped in #216, re-add it. Requires a way for mapper packages to signal the need for passing query args to HTTP requests
2018-01-24 19:09:02 -08:00
Łukasz Mierzwa
3f8368b8c2 Merge pull request #220 from cloudflare/vendor-updates
Vendor updates
2018-01-24 17:10:31 -08:00
Łukasz Mierzwa
1d1b7a4acb Update nodejs dependencies
New release is around the corner, update vendored packages so we can test it before the cut
2018-01-24 17:00:28 -08:00
Łukasz Mierzwa
14b248de91 Update Go vendor packages
New release will be cut soon, update vendored packages before that to allow testing
2018-01-24 17:00:28 -08:00
Łukasz Mierzwa
a31b182e4d Merge pull request #221 from cloudflare/tls-fix
Too many 'T' in NewHTTTPTransport
2018-01-24 14:12:50 -08:00
Łukasz Mierzwa
60b1c696a3 Too many 'T' in NewHTTTPTransport 2018-01-24 13:04:27 -08:00
Łukasz Mierzwa
0d228d2def Merge pull request #207 from cloudflare/tls-auth
Add support for passing path to custom TLS CA cert & client key/cert …
2018-01-24 12:21:35 -08:00
Łukasz Mierzwa
a0cf3cc43c Add a JSON tag for ProxyRequests attr 2018-01-23 21:38:46 -08:00
Łukasz Mierzwa
49d1ed2e1e Pass HTTP transport to the proxy
When we proxy requests we should use same transport as we use when collecting alerts & silences
2018-01-23 21:37:56 -08:00
Łukasz Mierzwa
d5a7cb9ace Rename Transport interface to Reader 2018-01-23 19:40:24 -08:00
Łukasz Mierzwa
6f89a77f8d Rename 'transport' package to 'uri'
This package adds handlers for different URI schemes, name clashes with http.Transport which is now passed around. Rename it to make it more obvious what it does
2018-01-23 19:32:39 -08:00
Łukasz Mierzwa
338a4c38a6 Drop duplicated function
There's identical method on the Alertmanager instance that's being used
2018-01-23 19:22:50 -08:00
Łukasz Mierzwa
24335ebf1f Add support for passing path to custom TLS CA cert & client key/cert pair
This adds support for passing a custom http.RoundTripper so in effect we can customize TLS client config for HTTPS requests.
Fixes #184
2018-01-23 19:22:12 -08:00
Łukasz Mierzwa
90a517bc9a Merge pull request #216 from cloudflare/mapper-refactor
Mapper package refactoring
2018-01-22 11:39:19 -08:00
Łukasz Mierzwa
c7fb8db98d Drop Release() from SilenceMapper
Not used
2018-01-22 11:26:36 -08:00
Łukasz Mierzwa
1f89ba05fe Migrate rest of the code to new mapper and transport packages 2018-01-22 11:26:36 -08:00
Łukasz Mierzwa
6124196b0f Finish refactoring mapper package
Fix bugs, add docstrings and let each mapper give us full url since it doesn't handle any http requests now (it just maps text to objects now)
2018-01-22 11:26:36 -08:00