Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/dev' into dev
Browse files Browse the repository at this point in the history
  • Loading branch information
mgianluc committed Dec 1, 2024
2 parents 3fa7fb0 + 421eae2 commit a850fbf
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
6 changes: 3 additions & 3 deletions internal/commands/show/admin_rbacs.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ import (
"k8s.io/apimachinery/pkg/types"

libsveltosv1beta1 "github.com/projectsveltos/libsveltos/api/v1beta1"
libsveltosutils "github.com/projectsveltos/libsveltos/lib/k8s_utils"
"github.com/projectsveltos/libsveltos/lib/k8s_utils"
logs "github.com/projectsveltos/libsveltos/lib/logsettings"
"github.com/projectsveltos/sveltosctl/internal/utils"
)
Expand Down Expand Up @@ -62,7 +62,7 @@ func displayAdminRbacs(ctx context.Context,
logger logr.Logger) error {

// Collect all RoleRequest
instance := k8s_utils.GetAccessInstance()
instance := utils.GetAccessInstance()

logger.V(logs.LogDebug).Info("collect all rolerequests")
roleRequests, err := instance.ListRoleRequests(ctx, logger)
Expand Down Expand Up @@ -270,7 +270,7 @@ func collectResourceContent(ctx context.Context, resource libsveltosv1beta1.Poli
logger = logger.WithValues("kind", resource.Kind,
"resource", fmt.Sprintf("%s/%s", resource.Namespace, resource.Name))
logger.V(logs.LogDebug).Info("collect resource")
instance := k8s_utils.GetAccessInstance()
instance := utils.GetAccessInstance()
if resource.Kind == string(libsveltosv1beta1.ConfigMapReferencedResourceKind) {
configMap := &corev1.ConfigMap{}
err := instance.GetResource(ctx,
Expand Down
3 changes: 2 additions & 1 deletion internal/commands/show/resources.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ import (
libsveltosv1beta1 "github.com/projectsveltos/libsveltos/api/v1beta1"
"github.com/projectsveltos/libsveltos/lib/k8s_utils"
logs "github.com/projectsveltos/libsveltos/lib/logsettings"
"github.com/projectsveltos/sveltosctl/internal/utils"
)

var (
Expand Down Expand Up @@ -82,7 +83,7 @@ func displayResourcesInNamespaces(ctx context.Context,
passedClusterNamespace, passedCluster, passedGroup, passedKind, passedNamespace string,
full bool, table *tablewriter.Table, logger logr.Logger) error {

instance := k8s_utils.GetAccessInstance()
instance := utils.GetAccessInstance()

healthCheckReports, err := instance.ListHealthCheckReports(ctx, passedClusterNamespace, logger)
if err != nil {
Expand Down

0 comments on commit a850fbf

Please sign in to comment.