From f7a222328f56e39de65c754671e18b843e56300d Mon Sep 17 00:00:00 2001 From: disaster37 Date: Fri, 14 Feb 2020 14:57:15 +0000 Subject: [PATCH 1/5] Add copy object resource --- README.md | 44 ++++- kb/provider.go | 1 + kb/resource_kibana_copy_object.go | 214 +++++++++++++++++++++++++ kb/resource_kibana_copy_object_test.go | 96 +++++++++++ kb/resource_kibana_object_test.go | 2 +- 5 files changed, 352 insertions(+), 5 deletions(-) create mode 100644 kb/resource_kibana_copy_object.go create mode 100644 kb/resource_kibana_copy_object_test.go diff --git a/README.md b/README.md index 2b9b329..1239f41 100644 --- a/README.md +++ b/README.md @@ -59,7 +59,7 @@ You can see the API documentation: https://www.elastic.co/guide/en/kibana/master ***Sample:*** ```tf -resource "kibana_role" "test" { +resource kibana_role "test" { name = "terraform-test" elasticsearch { indices { @@ -120,7 +120,7 @@ You can see the API documentation: https://www.elastic.co/guide/en/kibana/master ***Sample:*** ```tf -resource "kibana_user_space" "test" { +resource kibana_user_space "test" { name = "terraform-test" description = "test" initials = "tt" @@ -147,7 +147,7 @@ You can see the API documentation: https://www.elastic.co/guide/en/kibana/master ***Sample:*** ```tf -resource "kibana_object" "test" { +resource kibana_object "test" { name = "terraform-test" data = "${file("../fixtures/index-pattern.json")}" deep_reference = "true" @@ -168,6 +168,42 @@ resource "kibana_object" "test" { --- +### Copy saved object + +This resource permit to copy objects from space to another spaces. +You can see the API documentation: https://www.elastic.co/guide/en/kibana/master/spaces-api.html + +***Supported Kibana version:*** + - v7 + +***Sample:*** +```tf +resource kibana_copy_object "test" { + name = "terraform-test" + source_space = "default" + target_spaces = ["Team A"] + object { + id = "logstash-system-*" + type = "index-pattern" + } +} +``` + +***The following arguments are supported:*** + - **name**: (required) The unique name + - **source_space**: (optional) The user space from copy objects. Default to `default` + - **target_spaces**: (required) The list of space where to copy objects + - **overwrite**: (optional) Overwrite existing objects. Default to `true` + - **object**: (optional) The list of object you should to copy + - **include_reference**: (optional) Include reference when copy objects. Default to `true` + - **force_update**: (optional) Force to copy objects each time you apply. Default to `true` + +***object:*** + - **id**: (required) The object ID + - **type**: (required) The object type + +--- + ### Logstash pipeline management This resource permit to manage logstash pipeline in Kibana. @@ -178,7 +214,7 @@ You can see the API documentation: https://www.elastic.co/guide/en/kibana/master ***Sample:*** ```tf -resource "kibana_logstash_pipeline" "test" { +resource kibana_logstash_pipeline "test" { name = "terraform-test" description = "test" pipeline = "input { stdin {} } output { stdout {} }" diff --git a/kb/provider.go b/kb/provider.go index a4f06f9..1197869 100644 --- a/kb/provider.go +++ b/kb/provider.go @@ -74,6 +74,7 @@ func Provider() terraform.ResourceProvider { "kibana_role": resourceKibanaRole(), "kibana_object": resourceKibanaObject(), "kibana_logstash_pipeline": resourceKibanaLogstashPipeline(), + "kibana_copy_object": resourceKibanaCopyObject(), }, ConfigureFunc: providerConfigure, diff --git a/kb/resource_kibana_copy_object.go b/kb/resource_kibana_copy_object.go new file mode 100644 index 0000000..63924a0 --- /dev/null +++ b/kb/resource_kibana_copy_object.go @@ -0,0 +1,214 @@ +// Copy Kibana object from space to another spaces +// API documentation: https://www.elastic.co/guide/en/kibana/master/spaces-api-copy-saved-objects.html +// Supported version: +// - v7 + +package kb + +import ( + "fmt" + + kibana "github.com/disaster37/go-kibana-rest/v7" + "github.com/disaster37/go-kibana-rest/v7/kbapi" + + "github.com/hashicorp/terraform-plugin-sdk/helper/schema" + log "github.com/sirupsen/logrus" +) + +// Resource specification to handle kibana save object +func resourceKibanaCopyObject() *schema.Resource { + return &schema.Resource{ + Create: resourceKibanaCopyObjectCreate, + Read: resourceKibanaCopyObjectRead, + Update: resourceKibanaCopyObjectUpdate, + Delete: resourceKibanaCopyObjectDelete, + + Schema: map[string]*schema.Schema{ + "name": { + Type: schema.TypeString, + Required: true, + ForceNew: true, + }, + "source_space": { + Type: schema.TypeString, + Optional: true, + Default: "default", + }, + "target_spaces": { + Type: schema.TypeSet, + Required: true, + Elem: &schema.Schema{ + Type: schema.TypeString, + }, + }, + "object": { + Type: schema.TypeSet, + Required: true, + Elem: &schema.Resource{ + Schema: map[string]*schema.Schema{ + "id": { + Type: schema.TypeString, + Required: true, + }, + "type": { + Type: schema.TypeString, + Required: true, + }, + }, + }, + }, + "include_reference": { + Type: schema.TypeBool, + Optional: true, + Default: true, + }, + "overwrite": { + Type: schema.TypeBool, + Optional: true, + Default: true, + }, + "force_update": { + Type: schema.TypeBool, + Optional: true, + Computed: true, + }, + }, + } +} + +// Copy objects in Kibana +func resourceKibanaCopyObjectCreate(d *schema.ResourceData, meta interface{}) error { + name := d.Get("name").(string) + + err := copyObject(d, meta) + if err != nil { + return err + } + + d.SetId(name) + + log.Infof("Copy objects %s successfully", name) + + return resourceKibanaCopyObjectRead(d, meta) +} + +// Read object on kibana +func resourceKibanaCopyObjectRead(d *schema.ResourceData, meta interface{}) error { + + id := d.Id() + sourceSpace := d.Get("source_space").(string) + targetSpaces := convertArrayInterfaceToArrayString(d.Get("target_spaces").(*schema.Set).List()) + objects := buildCopyObjects(d.Get("object").(*schema.Set).List()) + includeReference := d.Get("include_reference").(bool) + overwrite := d.Get("overwrite").(bool) + forceUpdate := d.Get("force_update").(bool) + + log.Debugf("Resource id: %s", id) + log.Debugf("Source space: %s", sourceSpace) + log.Debugf("Target spaces: %+v", targetSpaces) + log.Debugf("Objects: %+v", objects) + log.Debugf("Include reference: %t", includeReference) + log.Debugf("Overwrite: %t", overwrite) + log.Debugf("force_update: %t", forceUpdate) + + // @ TODO + // A good when is to check if already exported object is the same that original space + // To avoid this hard code, we juste use force_update and overwrite field + // It make same result but in bad way on terraform spirit + + d.Set("name", id) + d.Set("source_space", sourceSpace) + d.Set("target_spaces", targetSpaces) + d.Set("object", objects) + d.Set("include_reference", includeReference) + d.Set("overwrite", overwrite) + d.Set("force_update", false) + + log.Infof("Read resource %s successfully", id) + + return nil +} + +// Update existing object in Kibana +func resourceKibanaCopyObjectUpdate(d *schema.ResourceData, meta interface{}) error { + id := d.Id() + + err := copyObject(d, meta) + if err != nil { + return err + } + + log.Infof("Updated resource %s successfully", id) + + return resourceKibanaCopyObjectRead(d, meta) +} + +// Delete object in Kibana is not supported +// It just remove object from state +func resourceKibanaCopyObjectDelete(d *schema.ResourceData, meta interface{}) error { + + d.SetId("") + + log.Infof("Delete object in not supported") + fmt.Printf("[INFO] Delete object in not supported - just removing from state") + return nil + +} + +// Build list of object to export +func buildCopyObjects(raws []interface{}) []map[string]string { + + results := make([]map[string]string, len(raws)) + + for i, raw := range raws { + m := raw.(map[string]interface{}) + object := map[string]string{} + object["type"] = m["type"].(string) + object["id"] = m["id"].(string) + results[i] = object + } + + return results +} + +// Copy objects in Kibana +func copyObject(d *schema.ResourceData, meta interface{}) error { + name := d.Get("name").(string) + sourceSpace := d.Get("source_space").(string) + targetSpaces := convertArrayInterfaceToArrayString(d.Get("target_spaces").(*schema.Set).List()) + objects := buildCopyObjects(d.Get("object").(*schema.Set).List()) + includeReference := d.Get("include_reference").(bool) + overwrite := d.Get("overwrite").(bool) + + log.Debugf("Source space: %s", sourceSpace) + log.Debugf("Target spaces: %+v", targetSpaces) + log.Debugf("Objects: %+v", objects) + log.Debugf("Include reference: %t", includeReference) + log.Debugf("Overwrite: %t", overwrite) + + client := meta.(*kibana.Client) + + objectsParameter := make([]kbapi.KibanaSpaceObjectParameter, 0, 1) + for _, object := range objects { + objectsParameter = append(objectsParameter, kbapi.KibanaSpaceObjectParameter{ + ID: object["id"], + Type: object["type"], + }) + } + + parameter := &kbapi.KibanaSpaceCopySavedObjectParameter{ + Spaces: targetSpaces, + Objects: objectsParameter, + IncludeReferences: includeReference, + Overwrite: overwrite, + } + + err := client.API.KibanaSpaces.CopySavedObjects(parameter, sourceSpace) + if err != nil { + return err + } + + log.Debugf("Copy object for resource successfully: %s", name) + + return nil +} diff --git a/kb/resource_kibana_copy_object_test.go b/kb/resource_kibana_copy_object_test.go new file mode 100644 index 0000000..53f4027 --- /dev/null +++ b/kb/resource_kibana_copy_object_test.go @@ -0,0 +1,96 @@ +package kb + +import ( + "fmt" + "testing" + + kibana "github.com/disaster37/go-kibana-rest/v7" + "github.com/hashicorp/terraform-plugin-sdk/helper/resource" + "github.com/hashicorp/terraform-plugin-sdk/terraform" + "github.com/pkg/errors" + log "github.com/sirupsen/logrus" +) + +func TestAccKibanaCopyObject(t *testing.T) { + + resource.Test(t, resource.TestCase{ + PreCheck: func() { + testAccPreCheck(t) + }, + Providers: testAccProviders, + CheckDestroy: testCheckKibanaCopyObjectDestroy, + Steps: []resource.TestStep{ + { + Config: testKibanaCopyObject, + Check: resource.ComposeTestCheckFunc( + testCheckKibanaCopyObjectExists("kibana_copy_object.test"), + ), + }, + }, + }) +} + +func testCheckKibanaCopyObjectExists(name string) resource.TestCheckFunc { + return func(s *terraform.State) error { + rs, ok := s.RootModule().Resources[name] + if !ok { + return fmt.Errorf("Not found: %s", name) + } + if rs.Primary.ID == "" { + return fmt.Errorf("No object ID is set") + } + + // Use static value that match the current test + objectID := "logstash-log-*" + objectType := "index-pattern" + targetSpace := "test" + + meta := testAccProvider.Meta() + + client := meta.(*kibana.Client) + data, err := client.API.KibanaSavedObject.Get(objectType, objectID, targetSpace) + if err != nil { + return err + } + if len(data) == 0 { + return errors.Errorf("Object %s not found", rs.Primary.ID) + } + + return nil + } +} + +func testCheckKibanaCopyObjectDestroy(s *terraform.State) error { + for _, rs := range s.RootModule().Resources { + if rs.Type != "kibana_copy_object" { + continue + } + + log.Debugf("We never delete kibana object") + } + + return nil +} + +var testKibanaCopyObject = ` +resource kibana_object "test" { + name = "terraform-test" + data = "${file("../fixtures/index-pattern.json")}" + deep_reference = "true" + export_types = ["index-pattern"] +} + +resource kibana_space "test" { + name = "terraform-test" +} + +resource kibana_copy_object "test" { + name = "terraform-test" + source_space = "default" + target_spaces = ["${kibana_space.test.id}"] + object { + id = "logstash-system-*" + type = "${kibana_object.test.export_types[0]}" + } +} +` diff --git a/kb/resource_kibana_object_test.go b/kb/resource_kibana_object_test.go index dd65a90..d234e27 100644 --- a/kb/resource_kibana_object_test.go +++ b/kb/resource_kibana_object_test.go @@ -65,7 +65,7 @@ func testCheckKibanaObjectExists(name string) resource.TestCheckFunc { func testCheckKibanaObjectDestroy(s *terraform.State) error { for _, rs := range s.RootModule().Resources { - if rs.Type != "kibana_user_space" { + if rs.Type != "kibana_object" { continue } From b170f41859dcaef143f9fb539214a0b85edfd83b Mon Sep 17 00:00:00 2001 From: disaster37 Date: Fri, 14 Feb 2020 16:52:17 +0000 Subject: [PATCH 2/5] Try to fix kibana copy object resource --- .circleci/config.yml | 4 ++-- fixtures/test.ndjson | 1 + go.mod | 2 +- go.sum | 2 ++ kb/resource_kibana_copy_object_test.go | 20 +++++++++++--------- 5 files changed, 17 insertions(+), 12 deletions(-) create mode 100644 fixtures/test.ndjson diff --git a/.circleci/config.yml b/.circleci/config.yml index 464d617..b042675 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -13,7 +13,7 @@ jobs: - KIBANA_URL: "http://kb:5601" - KIBANA_USERNAME: "elastic" - KIBANA_PASSWORD: "changeme" - - image: docker.elastic.co/elasticsearch/elasticsearch:7.4.2 + - image: docker.elastic.co/elasticsearch/elasticsearch:7.5.1 name: es environment: - cluster.name: "test" @@ -22,7 +22,7 @@ jobs: - xpack.security.enabled: "true" - ES_JAVA_OPTS: "-Xms512m -Xmx512m" - path.repo: "/tmp" - - image: docker.elastic.co/kibana/kibana:7.4.2 + - image: docker.elastic.co/kibana/kibana:7.5.1 name: kb environment: ELASTICSEARCH_HOSTS: http://es:9200 diff --git a/fixtures/test.ndjson b/fixtures/test.ndjson new file mode 100644 index 0000000..fff26ee --- /dev/null +++ b/fixtures/test.ndjson @@ -0,0 +1 @@ +{"id":"test","type":"index-pattern","attributes":{"title":"test"}} \ No newline at end of file diff --git a/go.mod b/go.mod index 488c878..605a4e3 100644 --- a/go.mod +++ b/go.mod @@ -3,7 +3,7 @@ module github.com/disaster37/terraform-provider-kibana/v7 go 1.12 require ( - github.com/disaster37/go-kibana-rest/v7 v7.4.2-2 + github.com/disaster37/go-kibana-rest/v7 v7.5.1-1 github.com/hashicorp/terraform-plugin-sdk v1.1.1 github.com/mitchellh/gox v1.0.1 github.com/pkg/errors v0.8.1 diff --git a/go.sum b/go.sum index d193b0e..7ec2a25 100644 --- a/go.sum +++ b/go.sum @@ -52,6 +52,8 @@ github.com/disaster37/go-kibana-rest/v7 v7.4.2-2 h1:rB8+FoQaa1zpTpsz4xpfP1+doR1A github.com/disaster37/go-kibana-rest/v7 v7.4.2-2/go.mod h1:Z87HQt6dkf7SvYqJinKPELp9HOPz15odL9ozK6iAXXI= github.com/disaster37/go-kibana-rest/v7 v7.4.2 h1:ZD/qMxvfwoQlHTMbU2po9BuamTNQXTM/ZxmJVQpzK/4= github.com/disaster37/go-kibana-rest/v7 v7.4.2/go.mod h1:Z87HQt6dkf7SvYqJinKPELp9HOPz15odL9ozK6iAXXI= +github.com/disaster37/go-kibana-rest/v7 v7.5.1-1 h1:/yK7P+7UNxt1jgOIjp1a9ezzXMus+X1gHtgLhVEUOYE= +github.com/disaster37/go-kibana-rest/v7 v7.5.1-1/go.mod h1:Z87HQt6dkf7SvYqJinKPELp9HOPz15odL9ozK6iAXXI= github.com/disaster37/terraform-provider-kibana v0.0.0-20191011125519-b57968904215 h1:+NezComO7Ky50C8qsDlSFZu/BgHvTLM/rBK3Zj3EE58= github.com/elastic/go-elasticsearch/v6 v6.8.2/go.mod h1:UwaDJsD3rWLM5rKNFzv9hgox93HoX8utj1kxD9aFUcI= github.com/elastic/go-elasticsearch/v7 v7.4.0/go.mod h1:OJ4wdbtDNk5g503kvlHLyErCgQwwzmDtaFC4XyOxXA4= diff --git a/kb/resource_kibana_copy_object_test.go b/kb/resource_kibana_copy_object_test.go index 53f4027..9ec3608 100644 --- a/kb/resource_kibana_copy_object_test.go +++ b/kb/resource_kibana_copy_object_test.go @@ -41,9 +41,9 @@ func testCheckKibanaCopyObjectExists(name string) resource.TestCheckFunc { } // Use static value that match the current test - objectID := "logstash-log-*" + objectID := "test" objectType := "index-pattern" - targetSpace := "test" + targetSpace := "terraform-test2" meta := testAccProvider.Meta() @@ -75,22 +75,24 @@ func testCheckKibanaCopyObjectDestroy(s *terraform.State) error { var testKibanaCopyObject = ` resource kibana_object "test" { name = "terraform-test" - data = "${file("../fixtures/index-pattern.json")}" + data = "${file("../fixtures/test.ndjson")}" deep_reference = "true" export_types = ["index-pattern"] } -resource kibana_space "test" { - name = "terraform-test" +resource kibana_user_space "test" { + name = "terraform-test2" } resource kibana_copy_object "test" { - name = "terraform-test" + name = "terraform-test2" source_space = "default" - target_spaces = ["${kibana_space.test.id}"] + target_spaces = ["terraform-test"] object { - id = "logstash-system-*" - type = "${kibana_object.test.export_types[0]}" + id = "test" + type = "index-pattern" } + + depends_on = [kibana_object.test, kibana_user_space.test] } ` From 5115e1fb14354f8151b788d47ca949ffe705b6ed Mon Sep 17 00:00:00 2001 From: disaster37 Date: Mon, 24 Feb 2020 10:09:45 +0000 Subject: [PATCH 3/5] Add resource to copy object --- kb/provider_test.go | 2 +- kb/resource_kibana_copy_object_test.go | 13 ++++++++++--- 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/kb/provider_test.go b/kb/provider_test.go index bd6ad45..3331db7 100644 --- a/kb/provider_test.go +++ b/kb/provider_test.go @@ -17,7 +17,7 @@ func init() { // Init logger logrus.SetFormatter(new(prefixed.TextFormatter)) - logrus.SetLevel(logrus.DebugLevel) + logrus.SetLevel(logrus.InfoLevel) // Init provider testAccProvider = Provider().(*schema.Provider) diff --git a/kb/resource_kibana_copy_object_test.go b/kb/resource_kibana_copy_object_test.go index 9ec3608..c63193c 100644 --- a/kb/resource_kibana_copy_object_test.go +++ b/kb/resource_kibana_copy_object_test.go @@ -25,6 +25,7 @@ func TestAccKibanaCopyObject(t *testing.T) { Check: resource.ComposeTestCheckFunc( testCheckKibanaCopyObjectExists("kibana_copy_object.test"), ), + ExpectNonEmptyPlan: true, }, }, }) @@ -52,7 +53,9 @@ func testCheckKibanaCopyObjectExists(name string) resource.TestCheckFunc { if err != nil { return err } + if len(data) == 0 { + panic(fmt.Sprintf("%+v", data)) return errors.Errorf("Object %s not found", rs.Primary.ID) } @@ -62,14 +65,18 @@ func testCheckKibanaCopyObjectExists(name string) resource.TestCheckFunc { func testCheckKibanaCopyObjectDestroy(s *terraform.State) error { for _, rs := range s.RootModule().Resources { - if rs.Type != "kibana_copy_object" { + log.Infof("RS TYPE: %s", rs.Type) + if (rs.Type != "kibana_copy_object") && (rs.Type != "kibana_object") { continue } - log.Debugf("We never delete kibana object") + log.Infof("We never delete kibana object") + return nil + } return nil + } var testKibanaCopyObject = ` @@ -87,7 +94,7 @@ resource kibana_user_space "test" { resource kibana_copy_object "test" { name = "terraform-test2" source_space = "default" - target_spaces = ["terraform-test"] + target_spaces = ["${kibana_user_space.test.name}"] object { id = "test" type = "index-pattern" From 9776f155520cf9068b60e9579bf5cc83f8462409 Mon Sep 17 00:00:00 2001 From: disaster37 Date: Mon, 24 Feb 2020 10:35:43 +0000 Subject: [PATCH 4/5] Fix acceptance test --- kb/resource_kibana_copy_object_test.go | 6 +- kb/resource_kibana_object_test.go | 1 + kb/resource_kibana_role_test.go | 4 +- trace.log | 163 +++++++++++++++++++++++++ 4 files changed, 168 insertions(+), 6 deletions(-) create mode 100644 trace.log diff --git a/kb/resource_kibana_copy_object_test.go b/kb/resource_kibana_copy_object_test.go index c63193c..ae2c021 100644 --- a/kb/resource_kibana_copy_object_test.go +++ b/kb/resource_kibana_copy_object_test.go @@ -65,13 +65,11 @@ func testCheckKibanaCopyObjectExists(name string) resource.TestCheckFunc { func testCheckKibanaCopyObjectDestroy(s *terraform.State) error { for _, rs := range s.RootModule().Resources { - log.Infof("RS TYPE: %s", rs.Type) - if (rs.Type != "kibana_copy_object") && (rs.Type != "kibana_object") { + if rs.Type != "kibana_copy_object" { continue } - log.Infof("We never delete kibana object") - return nil + log.Debugf("We never delete kibana object") } diff --git a/kb/resource_kibana_object_test.go b/kb/resource_kibana_object_test.go index d234e27..b29628e 100644 --- a/kb/resource_kibana_object_test.go +++ b/kb/resource_kibana_object_test.go @@ -25,6 +25,7 @@ func TestAccKibanaObject(t *testing.T) { Check: resource.ComposeTestCheckFunc( testCheckKibanaObjectExists("kibana_object.test"), ), + ExpectNonEmptyPlan: true, }, }, }) diff --git a/kb/resource_kibana_role_test.go b/kb/resource_kibana_role_test.go index 2c2a2d4..7aff472 100644 --- a/kb/resource_kibana_role_test.go +++ b/kb/resource_kibana_role_test.go @@ -84,7 +84,7 @@ func testCheckKibanaRoleDestroy(s *terraform.State) error { } var testKibanaRole = ` -resource "kibana_role" "test" { +resource kibana_role "test" { name = "terraform-test" elasticsearch { indices { @@ -93,7 +93,7 @@ resource "kibana_role" "test" { } indices { names = ["logstash-*"] - privileges = ["read2"] + privileges = ["read"] } cluster = ["all"] } diff --git a/trace.log b/trace.log new file mode 100644 index 0000000..27e403b --- /dev/null +++ b/trace.log @@ -0,0 +1,163 @@ +==> Fixing source code with gofmt... +gofmt -s -w ./kb +==> Checking that code complies with gofmt requirements... +KIBANA_URL=http://127.0.0.1:5601 KIBANA_USERNAME=elastic KIBANA_PASSWORD=changeme TF_ACC=1 go test ./... -v -count 1 -parallel 1 -race -coverprofile=coverage.txt -covermode=atomic -timeout 120m +? github.com/disaster37/terraform-provider-kibana/v7 [no test files] +=== RUN TestProvider +--- PASS: TestProvider (0.00s) +=== RUN TestProvider_impl +--- PASS: TestProvider_impl (0.00s) +=== RUN TestAccKibanaCopyObject +2020/02/24 10:33:30.263022 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:30Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:30.361320 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:30Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:30.405891 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +2020/02/24 10:33:30.406976 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:31Z" level=info msg="Imported objects terraform-test successfully" +2020/02/24 10:33:31.023976 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:31Z" level=info msg="Created user space terraform-test2 successfully" +2020/02/24 10:33:31.024783 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:31Z" level=info msg="Read user space terraform-test2 successfully" +time="2020-02-24T10:33:31Z" level=info msg="Export object terraform-test successfully" +2020/02/24 10:33:31.148847 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:32Z" level=info msg="Copy objects terraform-test2 successfully" +time="2020-02-24T10:33:32Z" level=info msg="Read resource terraform-test2 successfully" +2020/02/24 10:33:32.101613 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +2020/02/24 10:33:33.210826 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:33Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:33.736456 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:33Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:33.778898 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:33Z" level=info msg="Read user space terraform-test2 successfully" +2020/02/24 10:33:33.954612 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:33Z" level=info msg="Export object terraform-test successfully" +time="2020-02-24T10:33:34Z" level=info msg="Read resource terraform-test2 successfully" +2020/02/24 10:33:34.114470 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:34Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:34.644278 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:34Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:34.692373 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:34Z" level=info msg="Read user space terraform-test2 successfully" +2020/02/24 10:33:34.877431 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:34Z" level=info msg="Export object terraform-test successfully" +time="2020-02-24T10:33:34Z" level=info msg="Read resource terraform-test2 successfully" +2020/02/24 10:33:35.354425 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:35Z" level=info msg="[INFO] Using Kibana 7" +time="2020-02-24T10:33:35Z" level=info msg="Delete object in not supported" +[INFO] Delete object in not supported - just removing from state2020/02/24 10:33:35.405716 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:35Z" level=info msg="Delete object in not supported" +[INFO] Delete object in not supported - just removing from statetime="2020-02-24T10:33:36Z" level=info msg="Deleted user space terraform-test2 successfully" +time="2020-02-24T10:33:36Z" level=info msg="RS TYPE: kibana_user_space" +time="2020-02-24T10:33:36Z" level=info msg="RS TYPE: kibana_copy_object" +time="2020-02-24T10:33:36Z" level=info msg="We never delete kibana object" +--- PASS: TestAccKibanaCopyObject (5.97s) +=== RUN TestAccKibanaLogstashPipeline +2020/02/24 10:33:36.212215 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:36Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:36.301430 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:36Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:36.470630 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +--- FAIL: TestAccKibanaLogstashPipeline (0.37s) + testing.go:569: Step 0 error: errors during apply: + + Error: 403 Forbidden + + on /tmp/tf-test694265864/main.tf line 2: + (source code not available) + + +=== RUN TestAccKibanaObject +2020/02/24 10:33:36.580363 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:36Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:36.702208 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:36Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:36.812503 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:37Z" level=info msg="Imported objects terraform-test successfully" +2020/02/24 10:33:37.125468 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:37Z" level=info msg="Export object terraform-test successfully" +2020/02/24 10:33:37.289757 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +2020/02/24 10:33:37.320069 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:37Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:37.772354 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:37Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:37.999556 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:38Z" level=info msg="Export object terraform-test successfully" +2020/02/24 10:33:38.130905 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:38Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:38.725966 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:38Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:38.956309 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:38Z" level=info msg="Export object terraform-test successfully" +2020/02/24 10:33:39.412125 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:39Z" level=info msg="[INFO] Using Kibana 7" +time="2020-02-24T10:33:39Z" level=info msg="Delete object in not supported" +[INFO] Delete object in not supported - just removing from state--- PASS: TestAccKibanaObject (3.14s) +=== RUN TestAccKibanaRole +2020/02/24 10:33:39.767606 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:39Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:39.848752 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:39Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:39.927839 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +2020/02/24 10:33:40.047263 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:40Z" level=info msg="Created role terraform-test successfully" +2020/02/24 10:33:40.091672 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:40Z" level=info msg="Read role terraform-test successfully" +2020/02/24 10:33:40.118237 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +2020/02/24 10:33:40.155711 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:40Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:40.228498 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:40Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:40.274614 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:40Z" level=info msg="Read role terraform-test successfully" +2020/02/24 10:33:40.309099 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:40Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:40.388691 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:40Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:40.431597 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:40Z" level=info msg="Read role terraform-test successfully" +2020/02/24 10:33:40.499890 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:40Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:40.591806 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:40Z" level=info msg="Read role terraform-test successfully" +2020/02/24 10:33:40.649483 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:40Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:40.702981 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:40Z" level=info msg="Deleted role terraform-test successfully" +2020/02/24 10:33:40.782743 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +--- PASS: TestAccKibanaRole (1.15s) +=== RUN TestAccKibanaUserSpace +2020/02/24 10:33:40.898633 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:40Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:40.964134 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:40Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:41.024299 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:41Z" level=info msg="Created user space terraform-test successfully" +2020/02/24 10:33:41.134030 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:41Z" level=info msg="Read user space terraform-test successfully" +2020/02/24 10:33:41.168777 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +2020/02/24 10:33:41.210270 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:41Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:41.274319 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:41Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:41.322854 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:41Z" level=info msg="Read user space terraform-test successfully" +2020/02/24 10:33:41.355796 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:41Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:41.444727 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:41Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:41.488333 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:41Z" level=info msg="Read user space terraform-test successfully" +2020/02/24 10:33:41.668276 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:41Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:41.723250 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:41Z" level=info msg="Read user space terraform-test successfully" +2020/02/24 10:33:41.873986 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:41Z" level=info msg="[INFO] Using Kibana 7" +2020/02/24 10:33:41.912292 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +time="2020-02-24T10:33:42Z" level=info msg="Deleted user space terraform-test successfully" +2020/02/24 10:33:42.154361 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS +--- PASS: TestAccKibanaUserSpace (1.40s) +FAIL +coverage: 64.4% of statements +FAIL github.com/disaster37/terraform-provider-kibana/v7/kb 12.107s From 7fed999752c3b7b48971194f04ead6030b5fef32 Mon Sep 17 00:00:00 2001 From: disaster37 Date: Mon, 24 Feb 2020 10:56:07 +0000 Subject: [PATCH 5/5] remove trace --- trace.log | 163 ------------------------------------------------------ 1 file changed, 163 deletions(-) delete mode 100644 trace.log diff --git a/trace.log b/trace.log deleted file mode 100644 index 27e403b..0000000 --- a/trace.log +++ /dev/null @@ -1,163 +0,0 @@ -==> Fixing source code with gofmt... -gofmt -s -w ./kb -==> Checking that code complies with gofmt requirements... -KIBANA_URL=http://127.0.0.1:5601 KIBANA_USERNAME=elastic KIBANA_PASSWORD=changeme TF_ACC=1 go test ./... -v -count 1 -parallel 1 -race -coverprofile=coverage.txt -covermode=atomic -timeout 120m -? github.com/disaster37/terraform-provider-kibana/v7 [no test files] -=== RUN TestProvider ---- PASS: TestProvider (0.00s) -=== RUN TestProvider_impl ---- PASS: TestProvider_impl (0.00s) -=== RUN TestAccKibanaCopyObject -2020/02/24 10:33:30.263022 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:30Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:30.361320 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:30Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:30.405891 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -2020/02/24 10:33:30.406976 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:31Z" level=info msg="Imported objects terraform-test successfully" -2020/02/24 10:33:31.023976 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:31Z" level=info msg="Created user space terraform-test2 successfully" -2020/02/24 10:33:31.024783 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:31Z" level=info msg="Read user space terraform-test2 successfully" -time="2020-02-24T10:33:31Z" level=info msg="Export object terraform-test successfully" -2020/02/24 10:33:31.148847 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:32Z" level=info msg="Copy objects terraform-test2 successfully" -time="2020-02-24T10:33:32Z" level=info msg="Read resource terraform-test2 successfully" -2020/02/24 10:33:32.101613 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -2020/02/24 10:33:33.210826 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:33Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:33.736456 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:33Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:33.778898 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:33Z" level=info msg="Read user space terraform-test2 successfully" -2020/02/24 10:33:33.954612 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:33Z" level=info msg="Export object terraform-test successfully" -time="2020-02-24T10:33:34Z" level=info msg="Read resource terraform-test2 successfully" -2020/02/24 10:33:34.114470 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:34Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:34.644278 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:34Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:34.692373 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:34Z" level=info msg="Read user space terraform-test2 successfully" -2020/02/24 10:33:34.877431 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:34Z" level=info msg="Export object terraform-test successfully" -time="2020-02-24T10:33:34Z" level=info msg="Read resource terraform-test2 successfully" -2020/02/24 10:33:35.354425 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:35Z" level=info msg="[INFO] Using Kibana 7" -time="2020-02-24T10:33:35Z" level=info msg="Delete object in not supported" -[INFO] Delete object in not supported - just removing from state2020/02/24 10:33:35.405716 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:35Z" level=info msg="Delete object in not supported" -[INFO] Delete object in not supported - just removing from statetime="2020-02-24T10:33:36Z" level=info msg="Deleted user space terraform-test2 successfully" -time="2020-02-24T10:33:36Z" level=info msg="RS TYPE: kibana_user_space" -time="2020-02-24T10:33:36Z" level=info msg="RS TYPE: kibana_copy_object" -time="2020-02-24T10:33:36Z" level=info msg="We never delete kibana object" ---- PASS: TestAccKibanaCopyObject (5.97s) -=== RUN TestAccKibanaLogstashPipeline -2020/02/24 10:33:36.212215 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:36Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:36.301430 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:36Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:36.470630 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS ---- FAIL: TestAccKibanaLogstashPipeline (0.37s) - testing.go:569: Step 0 error: errors during apply: - - Error: 403 Forbidden - - on /tmp/tf-test694265864/main.tf line 2: - (source code not available) - - -=== RUN TestAccKibanaObject -2020/02/24 10:33:36.580363 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:36Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:36.702208 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:36Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:36.812503 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:37Z" level=info msg="Imported objects terraform-test successfully" -2020/02/24 10:33:37.125468 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:37Z" level=info msg="Export object terraform-test successfully" -2020/02/24 10:33:37.289757 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -2020/02/24 10:33:37.320069 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:37Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:37.772354 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:37Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:37.999556 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:38Z" level=info msg="Export object terraform-test successfully" -2020/02/24 10:33:38.130905 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:38Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:38.725966 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:38Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:38.956309 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:38Z" level=info msg="Export object terraform-test successfully" -2020/02/24 10:33:39.412125 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:39Z" level=info msg="[INFO] Using Kibana 7" -time="2020-02-24T10:33:39Z" level=info msg="Delete object in not supported" -[INFO] Delete object in not supported - just removing from state--- PASS: TestAccKibanaObject (3.14s) -=== RUN TestAccKibanaRole -2020/02/24 10:33:39.767606 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:39Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:39.848752 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:39Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:39.927839 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -2020/02/24 10:33:40.047263 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:40Z" level=info msg="Created role terraform-test successfully" -2020/02/24 10:33:40.091672 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:40Z" level=info msg="Read role terraform-test successfully" -2020/02/24 10:33:40.118237 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -2020/02/24 10:33:40.155711 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:40Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:40.228498 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:40Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:40.274614 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:40Z" level=info msg="Read role terraform-test successfully" -2020/02/24 10:33:40.309099 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:40Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:40.388691 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:40Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:40.431597 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:40Z" level=info msg="Read role terraform-test successfully" -2020/02/24 10:33:40.499890 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:40Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:40.591806 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:40Z" level=info msg="Read role terraform-test successfully" -2020/02/24 10:33:40.649483 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:40Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:40.702981 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:40Z" level=info msg="Deleted role terraform-test successfully" -2020/02/24 10:33:40.782743 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS ---- PASS: TestAccKibanaRole (1.15s) -=== RUN TestAccKibanaUserSpace -2020/02/24 10:33:40.898633 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:40Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:40.964134 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:40Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:41.024299 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:41Z" level=info msg="Created user space terraform-test successfully" -2020/02/24 10:33:41.134030 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:41Z" level=info msg="Read user space terraform-test successfully" -2020/02/24 10:33:41.168777 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -2020/02/24 10:33:41.210270 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:41Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:41.274319 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:41Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:41.322854 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:41Z" level=info msg="Read user space terraform-test successfully" -2020/02/24 10:33:41.355796 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:41Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:41.444727 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:41Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:41.488333 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:41Z" level=info msg="Read user space terraform-test successfully" -2020/02/24 10:33:41.668276 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:41Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:41.723250 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:41Z" level=info msg="Read user space terraform-test successfully" -2020/02/24 10:33:41.873986 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:41Z" level=info msg="[INFO] Using Kibana 7" -2020/02/24 10:33:41.912292 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS -time="2020-02-24T10:33:42Z" level=info msg="Deleted user space terraform-test successfully" -2020/02/24 10:33:42.154361 WARN RESTY Using Basic Auth in HTTP mode is not secure, use HTTPS ---- PASS: TestAccKibanaUserSpace (1.40s) -FAIL -coverage: 64.4% of statements -FAIL github.com/disaster37/terraform-provider-kibana/v7/kb 12.107s