fix amtool: Fixed config path check in amtool (#1538)

Signed-off-by: Martin Chodur <m.chodur@seznam.cz>
This commit is contained in:
Martin Chodur 2018-09-03 06:06:01 +02:00 committed by stuart nelson
parent b1a8fdd169
commit 20bdaaf949
2 changed files with 4 additions and 0 deletions

View File

@ -3,6 +3,7 @@
* [CHANGE] Revert Alertmanager working directory changes in Docker image back to `/alertmanager` (#1435)
* [CHANGE] Remove `api/v1/alerts/groups` GET endpoint (#1508)
* [FEATURE] [amtool] Added `config routes` tools for vizualization and testing routes (#1511)
* [BUGFIX] [amtool] Fixed issue with loading path of a default configs (#1529)
## 0.15.2 / 2018-08-14

View File

@ -34,6 +34,9 @@ type Resolver struct {
func NewResolver(files []string, legacyFlags map[string]string) (*Resolver, error) {
flags := map[string]string{}
for _, f := range files {
if _, err := os.Stat(f); err != nil {
continue
}
b, err := ioutil.ReadFile(f)
if err != nil {
if os.IsNotExist(err) {