Skip to content

Commit

Permalink
Merge pull request #68 from ewilde/pn-update-go-kibana
Browse files Browse the repository at this point in the history
Update go-kibana
  • Loading branch information
pengux authored Mar 25, 2021
2 parents dcbaa3d + 9cce4be commit 9d3f8e4
Show file tree
Hide file tree
Showing 11 changed files with 37 additions and 10 deletions.
5 changes: 3 additions & 2 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ jobs:
fail-fast: false
matrix:
include:
- ELK_VERSION: 7.2.1
- ELK_VERSION: 7.6.1
KIBANA_TYPE: KibanaTypeLogzio
MAKELOGS_VERSION: '@elastic/[email protected]'
steps:
Expand All @@ -126,11 +126,12 @@ jobs:
env:
ELK_VERSION: ${{ matrix.ELK_VERSION }}
KIBANA_TYPE: ${{ matrix.KIBANA_TYPE }}
KIBANA_URI: 'https://app-eu.logz.io'
KIBANA_URI: 'https://app-eu.logz.io/kibana-7-6'
ELASTIC_SEARCH_PATH: '/kibana/elasticsearch/logzioCustomerKibanaIndex'
MAKELOGS_VERSION: ${{ matrix.MAKELOGS_VERSION }}
KIBANA_USERNAME: ${{ secrets.KIBANA_USERNAME }}
KIBANA_PASSWORD: ${{ secrets.KIBANA_PASSWORD }}
LOGZ_URL: 'https://app-eu.logz.io'
LOGZ_CLIENT_ID: ${{ secrets.LOGZ_CLIENT_ID }}
LOGZ_MFA_SECRET: ${{ secrets.LOGZ_MFA_SECRET }}

Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ require (
github.com/Microsoft/go-winio v0.4.15 // indirect
github.com/cenkalti/backoff v2.2.1+incompatible // indirect
github.com/containerd/continuity v0.0.0-20200928162600-f2cc35102c2a // indirect
github.com/ewilde/go-kibana v0.0.0-20210312090537-1c39d951b736
github.com/ewilde/go-kibana v0.0.0-20210325142727-7a2d527c3f8c
github.com/hashicorp/hcl v0.0.0-20171017181929-23c074d0eceb // indirect
github.com/hashicorp/terraform-plugin-sdk v1.16.0
github.com/mcuadros/go-version v0.0.0-20190830083331-035f6764e8d2
Expand Down
4 changes: 4 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,8 @@ github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1m
github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c=
github.com/ewilde/go-kibana v0.0.0-20210312090537-1c39d951b736 h1:GxY1w9631ijxBzWjiPrPsRSTCQv/JNc0a39RTMbx4/M=
github.com/ewilde/go-kibana v0.0.0-20210312090537-1c39d951b736/go.mod h1:QqYl0aCvJWhxdEEk/fleOzj9syUnx63B7DSaT4MEDrU=
github.com/ewilde/go-kibana v0.0.0-20210325142727-7a2d527c3f8c h1:Y58NU4Mpsu8eQj4CYHeZv5DKgcOy8pNucBfRfag7bKE=
github.com/ewilde/go-kibana v0.0.0-20210325142727-7a2d527c3f8c/go.mod h1:/uEUlwXJ0qwq4vizCl0WAmIJY65nG8YKvY3VldPR6NY=
github.com/fatih/color v1.7.0 h1:DkWD4oS2D8LGGgTQ6IvwJJXSL5Vp2ffcQg58nFV38Ys=
github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4=
github.com/flynn/go-shlex v0.0.0-20150515145356-3f9db97f8568 h1:BHsljHzVlRcyQhjrss6TZTdY2VfCqZPbv5k3iBFa2ZQ=
Expand Down Expand Up @@ -356,6 +358,7 @@ github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXf
github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI=
github.com/stretchr/testify v1.4.0 h1:2E4SXV/wtOkTonXsotYi4li6zVWxYlZuYNCXe9XRJyk=
github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4=
github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
github.com/ulikunitz/xz v0.5.5/go.mod h1:2bypXElzHzzJZwzH67Y6wb67pO62Rzfn7BSiF4ABRW8=
github.com/ulikunitz/xz v0.5.7 h1:YvTNdFzX6+W5m9msiYg/zpkSURPPtOlzbqYjrFn7Yt4=
github.com/ulikunitz/xz v0.5.7/go.mod h1:nbz6k7qbPmH4IRqmfOplQw/tblSgqTqBwxkY0oWt/14=
Expand Down Expand Up @@ -616,6 +619,7 @@ gopkg.in/warnings.v0 v0.1.2/go.mod h1:jksf8JmL6Qr/oQM2OXTHunEvvTAsrWBLb6OOjuVWRN
gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
gopkg.in/yaml.v2 v2.2.4 h1:/eiJrUcujPVeJ3xlSWaiNi3uSVmDGBK1pDHUHAnao1I=
gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
gotest.tools v2.2.0+incompatible h1:VsBPFP1AI068pPrMxtb/S8Zkgf9xEmTLJjfM+P5UIEo=
gotest.tools v2.2.0+incompatible/go.mod h1:DsYFclhRJ6vuDpmuTbkuFWG+y2sxOXAzmJt81HFBacw=
honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
Expand Down
10 changes: 8 additions & 2 deletions kibana/provider.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,12 @@ package kibana

import (
"fmt"
"github.com/hashicorp/terraform-plugin-sdk/terraform"
"log"
"os"
"sync"

"github.com/hashicorp/terraform-plugin-sdk/terraform"

"github.com/ewilde/go-kibana"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
)
Expand Down Expand Up @@ -181,9 +182,14 @@ func getAuthHandler(config *kibana.Config, d *schema.ResourceData) kibana.Authen
}

func getLogzioAuthHandler(config *kibana.Config, d *schema.ResourceData) kibana.AuthenticationHandler {
url := config.KibanaBaseUri
if v := os.Getenv(kibana.EnvLogzURL); v != "" {
url = v
}

return &kibana.LogzAuthenticationHandler{
Auth0Uri: "https://logzio.auth0.com",
LogzUri: config.KibanaBaseUri,
LogzUri: url,
ClientId: d.Get("logzio_client_id").(string),
UserName: d.Get("kibana_username").(string),
Password: d.Get("kibana_password").(string),
Expand Down
4 changes: 2 additions & 2 deletions vendor/github.com/ewilde/go-kibana/.travis.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion vendor/github.com/ewilde/go-kibana/README.md

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion vendor/github.com/ewilde/go-kibana/go.mod

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 10 additions & 0 deletions vendor/github.com/ewilde/go-kibana/go.sum

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions vendor/github.com/ewilde/go-kibana/kibana_client.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 4 additions & 0 deletions vendor/github.com/ewilde/go-kibana/testing.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion vendor/modules.txt
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ github.com/emirpasic/gods/lists/arraylist
github.com/emirpasic/gods/trees
github.com/emirpasic/gods/trees/binaryheap
github.com/emirpasic/gods/utils
# github.com/ewilde/go-kibana v0.0.0-20210312090537-1c39d951b736
# github.com/ewilde/go-kibana v0.0.0-20210325142727-7a2d527c3f8c
github.com/ewilde/go-kibana
# github.com/fatih/color v1.7.0
github.com/fatih/color
Expand Down

0 comments on commit 9d3f8e4

Please sign in to comment.