Skip to content

Commit

Permalink
Oracle Provider
Browse files Browse the repository at this point in the history
Signed-off-by: Anders Swanson <anders.swanson@oracle.com>
  • Loading branch information
anders-swanson committed Jan 19, 2024
1 parent f21a777 commit 49bedf0
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion pkg/cloud/oracle/key.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package oracle
import (
"fmt"

"github.com/opencost/opencost/pkg/util"
"github.com/opencost/opencost/core/pkg/util"
)

type oracleKey struct {
Expand Down
10 changes: 5 additions & 5 deletions pkg/cloud/oracle/provider.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,14 @@ import (
"sync"
"time"

"github.com/opencost/opencost/core/pkg/log"
"github.com/opencost/opencost/core/pkg/opencost"
"github.com/opencost/opencost/core/pkg/util"
"github.com/opencost/opencost/core/pkg/util/json"
"github.com/opencost/opencost/pkg/cloud/models"
"github.com/opencost/opencost/pkg/cloud/utils"
"github.com/opencost/opencost/pkg/clustercache"
"github.com/opencost/opencost/pkg/env"
"github.com/opencost/opencost/pkg/kubecost"
"github.com/opencost/opencost/pkg/log"
"github.com/opencost/opencost/pkg/util"
"github.com/opencost/opencost/pkg/util/json"
v1 "k8s.io/api/core/v1"
)

Expand Down Expand Up @@ -47,7 +47,7 @@ func (o *Oracle) ClusterInfo() (map[string]string, error) {
if clusterName := o.getClusterName(c); clusterName != "" {
m["name"] = clusterName
}
m["provider"] = kubecost.OracleProvider
m["provider"] = opencost.OracleProvider
m["account"] = o.ClusterAccountID
m["region"] = o.ClusterRegion
m["remoteReadEnabled"] = strconv.FormatBool(env.IsRemoteEnabled())
Expand Down
4 changes: 2 additions & 2 deletions pkg/cloud/provider/provider.go
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@ func NewProvider(cache clustercache.ClusterCache, apiKey string, config *config.
ClusterAccountID: cp.accountID,
Config: NewProviderConfig(config, cp.configFileName),
}, nil
case kubecost.OracleProvider:
case opencost.OracleProvider:
log.Info("Found ProviderID starting with \"oracle\", using Oracle Provider")
return &oracle.Oracle{
Clientset: cache,
Expand Down Expand Up @@ -297,7 +297,7 @@ func getClusterProperties(node *v1.Node) clusterProperties {
cp.provider = opencost.AlibabaProvider
cp.configFileName = "alibaba.json"
} else if strings.HasPrefix(providerID, "ocid") {
cp.provider = kubecost.OracleProvider
cp.provider = opencost.OracleProvider
cp.configFileName = "oracle.json"
}
if env.IsUseCSVProvider() {
Expand Down

0 comments on commit 49bedf0

Please sign in to comment.