Skip to content

Commit

Permalink
Block gateway network update for stratos (IBM-Cloud#429)
Browse files Browse the repository at this point in the history
  • Loading branch information
ismirlia authored Jul 29, 2024
1 parent 024c63c commit 4710183
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions clients/instance/ibm-pi-network.go
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,10 @@ func (f *IBMPINetworkClient) Create(body *models.NetworkCreate) (*models.Network

// Update a Network
func (f *IBMPINetworkClient) Update(id string, body *models.NetworkUpdate) (*models.Network, error) {
// Check for satellite differences in this endpoint
if f.session.IsOnPrem() && body.Gateway != nil {
return nil, fmt.Errorf("gateway parameter is not supported in satellite location, check documentation")
}
params := p_cloud_networks.NewPcloudNetworksPutParams().
WithContext(f.ctx).WithTimeout(helpers.PIUpdateTimeOut).
WithCloudInstanceID(f.cloudInstanceID).WithNetworkID(id).
Expand Down

0 comments on commit 4710183

Please sign in to comment.