-
Notifications
You must be signed in to change notification settings - Fork 20
/
apikey.go
27 lines (23 loc) · 919 Bytes
/
apikey.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
/*******************************************************************************
* IBM Confidential
* OCO Source Materials
* IBM Cloud Container Service, 5737-D43
* (C) Copyright IBM Corp. 2018, 2019 All Rights Reserved.
* The source code for this program is not published or otherwise divested of
* its trade secrets, irrespective of what has been deposited with
* the U.S. Copyright Office.
******************************************************************************/
package auth
import (
"go.uber.org/zap"
"github.com/IBM/ibmcloud-storage-volume-lib/lib/provider"
)
// ForIaaSAPIKey ...
func (ccf *ContextCredentialsFactory) ForIaaSAPIKey(iamAccountID, userid, apikey string, logger *zap.Logger) (provider.ContextCredentials, error) {
return provider.ContextCredentials{
AuthType: provider.IaaSAPIKey,
IAMAccountID: iamAccountID,
UserID: userid,
Credential: apikey,
}, nil
}