Skip to content

Commit

Permalink
update gophercloud v2
Browse files Browse the repository at this point in the history
  • Loading branch information
Vladimir Ermakov committed Mar 12, 2024
1 parent 55de0da commit 0d9ea37
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
2 changes: 0 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@ module github.com/sardinasystems/sensu-go-openstack-service-handler

go 1.22

exclude github.com/gophercloud/gophercloud/v2 v2.0.0-beta.1

require (
github.com/gophercloud/gophercloud/v2 v2.0.0-beta.2
github.com/gophercloud/utils/v2 v2.0.0-20240305212012-b57aefba4cdb
Expand Down
4 changes: 2 additions & 2 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ func handleCompute(ctx context.Context, pc *gophercloud.ProviderClient, eo gophe
Binary: plugin.Binary,
Host: host,
}
pages, err := os_services.List(cli, query).AllPages()
pages, err := os_services.List(cli, query).AllPages(ctx)
if err != nil {
return fmt.Errorf("Compute services list error: %w", err)
}
Expand Down Expand Up @@ -222,7 +222,7 @@ func handleCompute(ctx context.Context, pc *gophercloud.ProviderClient, eo gophe
}

log.Printf("Apply action: %s", updateOpts.Status)
_, err = os_services.Update(cli, computeID, updateOpts).Extract()
_, err = os_services.Update(ctx, cli, computeID, updateOpts).Extract()
if err != nil {
return fmt.Errorf("Compute service id: %s update error: %w", computeID, err)
}
Expand Down

0 comments on commit 0d9ea37

Please sign in to comment.