Skip to content
This repository was archived by the owner on Aug 12, 2025. It is now read-only.

Commit 1f22539

Browse files
committed
Use packet.NewClient for consistency
Signed-off-by: Chris Privitere <[email protected]>
1 parent 5a8fc7f commit 1f22539

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

cmd/ci-clean/main.go

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,7 @@ import (
2727
"github.com/packethost/packngo"
2828
"github.com/spf13/cobra"
2929
kerrors "k8s.io/apimachinery/pkg/util/errors"
30-
31-
"sigs.k8s.io/cluster-api-provider-packet/version"
30+
"sigs.k8s.io/cluster-api-provider-packet/pkg/cloud/packet"
3231
)
3332

3433
const (
@@ -65,8 +64,7 @@ func main() {
6564
}
6665

6766
func cleanup(metalAuthToken, metalProjectID string) error {
68-
metalClient := packngo.NewClientWithAuth("capp-e2e", metalAuthToken, nil)
69-
metalClient.UserAgent = fmt.Sprintf("capp-e2e/%s %s", version.Get(), metalClient.UserAgent)
67+
metalClient := packet.NewClient(metalAuthToken)
7068
listOpts := &packngo.ListOptions{}
7169
var errs []error
7270

0 commit comments

Comments
 (0)