Skip to content

Recent breaking change in IKS Softlayer config  #171

@depohmel

Description

@depohmel

IKS(Ibm Kubernetes service) recently was switched to use [Softlayer] encryption = true this change broke the current implementation of a https://github.com/IBM/ibmcloud-storage-volume-lib/blob/3ec50135ca49679fa3cb5748615dd7231ebf7f4e/config/config.go

Currently type SoftlayerConfig struct { doesn't support encryption field.

if you trying to use encryption = true you will receive following errors

"level":"info","ts":1568179589.4037242,"caller":"utils/init_provider.go:44","msg":"Block softlayer provider volume registry done!"}
{"level":"info","ts":1568179589.4037993,"caller":"utils/init_provider.go:93","msg":"Provider registration done!!!"}
{"level":"info","ts":1568179589.4038255,"caller":"utils/init_provider.go:133","msg":"Generating generateContextCredentials for ","Provider ID":"SOFTLAYER-BLOCK"}
{"level":"info","ts":1568179589.4038646,"caller":"iam/token_exchange.go:180","msg":"Sending IAM token exchange request"}
{"level":"error","ts":1568179589.823081,"caller":"iam/token_exchange.go:201","msg":"IAM token exchange request failed with message","StatusCode":400,"ErrorMessage:":"Provided API key could not be found","ErrorType:":"BXNIM0415E","Error":{"errorMessage":"Provided API key could not be found","errorCode":"BXNIM0415E","errorDetails":"","requirements":{"error":"","code":""}},"stacktrace":"github.com/IBM/ibmcloud-storage-volume-lib/volume-providers/iam.(*tokenExchangeRequest).sendTokenExchangeRequest\n\t/go/pkg/mod/github.com/!i!b!m/[email protected]/volume-providers/iam/token_exchange.go:201\ngithub.com/IBM/ibmcloud-storage-volume-lib/volume-providers/iam.(*tokenExchangeRequest).exchangeForIMSToken.func1\n\t/go/pkg/mod/github.com/!i!b!m/[email protected]/volume-providers/iam/token_exchange.go:134\ngithub.com/IBM/ibmcloud-storage-volume-lib/lib/utils.(*ErrorRetrier).ErrorRetry\n\t/go/pkg/mod/github.com/!i!b!m/[email protected]/lib/utils/error_utils.go:150\ngithub.com/IBM/ibmcloud-storage-volume-lib/volume-providers/iam.(*tokenExchangeRequest).exchangeForIMSToken\n\t/go/pkg/mod/github.com/!i!b!m/[email protected]/volume-providers/iam/token_exchange.go:133\ngithub.com/IBM/ibmcloud-storage-volume-lib/volume-providers/iam.(*tokenExchangeService).ExchangeIAMAPIKeyForIMSToken\n\t/go/pkg/mod/github.com/!i!b!m/[email protected]/volume-providers/iam/token_exchange.go:102\ngithub.com/IBM/ibmcloud-storage-volume-lib/volume-providers/auth.(*ContextCredentialsFactory).ForIAMAPIKey\n\t/go/pkg/mod/github.com/!i!b!m/[email protected]/volume-providers/auth/ims_token.go:54\ngithub.com/IBM/ibmcloud-storage-volume-lib/provider/utils.GenerateContextCredentials\n\t/go/pkg/mod/github.com/!i!b!m/[email protected]/provider/utils/init_provider.go:151\ngithub.com/IBM/ibmcloud-storage-volume-lib/provider/utils.OpenProviderSession\n\t/go/pkg/mod/github.com/!i!b!m/[email protected]/provider/utils/init_provider.go:119\ngithub.com/kanisterio/kanister/pkg/blockstorage/ibm.newClient\n\t/go/src/github.com/kanisterio/kanister/pkg/blockstorage/ibm/client.go:100\ngithub.com/kanisterio/kanister/pkg/blockstorage/ibm.(*ClientSuite).TestAPIClient\n\t/go/src/github.com/kanisterio/kanister/pkg/blockstorage/ibm/client_test.go:65\nreflect.Value.call\n\t/usr/local/go/src/reflect/value.go:447\nreflect.Value.Call\n\t/usr/local/go/src/reflect/value.go:308\ngopkg.in/check%2ev1.(*suiteRunner).forkTest.func1\n\t/go/pkg/mod/gopkg.in/[email protected]/check.go:781\ngopkg.in/check%2ev1.(*suiteRunner).forkCall.func1\n\t/go/pkg/mod/gopkg.in/[email protected]/check.go:675"}
{"level":"error","ts":1568179589.8233857,"caller":"auth/ims_token.go:57","msg":"Unable to retrieve IMS credentials from IAM API key","error":"IAM token exchange request failed: Provided API key could not be found","stacktrace":"github.com/IBM/ibmcloud-storage-volume-lib/volume-providers/auth.(*ContextCredentialsFactory).ForIAMAPIKey\n\t/go/pkg/mod/github.com/!i!b!m/[email protected]/volume-providers/auth/ims_token.go:57\ngithub.com/IBM/ibmcloud-storage-volume-lib/provider/utils.GenerateContextCredentials\n\t/go/pkg/mod/github.com/!i!b!m/[email protected]/provider/utils/init_provider.go:151\ngithub.com/IBM/ibmcloud-storage-volume-lib/provider/utils.OpenProviderSession\n\t/go/pkg/mod/github.com/!i!b!m/[email protected]/provider/utils/init_provider.go:119\ngithub.com/kanisterio/kanister/pkg/blockstorage/ibm.newClient\n\t/go/src/github.com/kanisterio/kanister/pkg/blockstorage/ibm/client.go:100\ngithub.com/kanisterio/kanister/pkg/blockstorage/ibm.(*ClientSuite).TestAPIClient\n\t/go/src/github.com/kanisterio/kanister/pkg/blockstorage/ibm/client_test.go:65\nreflect.Value.call\n\t/usr/local/go/src/reflect/value.go:447\nreflect.Value.Call\n\t/usr/local/go/src/reflect/value.go:308\ngopkg.in/check%2ev1.(*suiteRunner).forkTest.func1\n\t/go/pkg/mod/gopkg.in/[email protected]/check.go:781\ngopkg.in/check%2ev1.(*suiteRunner).forkCall.func1\n\t/go/pkg/mod/gopkg.in/[email protected]/check.go:675"}
{"level":"error","ts":1568179589.8235552,"caller":"utils/init_provider.go:126","msg":"Failed to open provider session","error":"IAM token exchange request failed: Provided API key could not be found","Fatal":true,"stacktrace":"github.com/IBM/ibmcloud-storage-volume-lib/provider/utils.OpenProviderSession\n\t/go/pkg/mod/github.com/!i!b!m/[email protected]/provider/utils/init_provider.go:126\ngithub.com/kanisterio/kanister/pkg/blockstorage/ibm.newClient\n\t/go/src/github.com/kanisterio/kanister/pkg/blockstorage/ibm/client.go:100\ngithub.com/kanisterio/kanister/pkg/blockstorage/ibm.(*ClientSuite).TestAPIClient\n\t/go/src/github.com/kanisterio/kanister/pkg/blockstorage/ibm/client_test.go:65\nreflect.Value.call\n\t/usr/local/go/src/reflect/value.go:447\nreflect.Value.Call\n\t/usr/local/go/src/reflect/value.go:308\ngopkg.in/check%2ev1.(*suiteRunner).forkTest.func1\n\t/go/pkg/mod/gopkg.in/[email protected]/check.go:781\ngopkg.in/check%2ev1.(*suiteRunner).forkCall.func1\n\t/go/pkg/mod/gopkg.in/[email protected]/check.go:675"}
Collapse

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions