fix: update lego.

This commit is contained in:
Ludovic Fernandez
2019-04-23 11:40:06 +02:00
committed by Traefiker Bot
parent 9559a56011
commit a6d86cdddb
167 changed files with 12066 additions and 986 deletions

View File

@@ -2,6 +2,7 @@ package api
import (
"fmt"
"github.com/sacloud/libsacloud/sacloud"
)
@@ -81,3 +82,26 @@ func (api *InterfaceAPI) DisconnectFromPacketFilter(interfaceID int64) (bool, er
)
return api.modify(method, uri, nil)
}
// SetDisplayIPAddress 表示用IPアドレス 設定
func (api *InterfaceAPI) SetDisplayIPAddress(interfaceID int64, ipaddress string) (bool, error) {
var (
method = "PUT"
uri = fmt.Sprintf("/%s/%d", api.getResourceURL(), interfaceID)
)
body := map[string]interface{}{
"Interface": map[string]string{
"UserIPAddress": ipaddress,
},
}
return api.modify(method, uri, body)
}
// DeleteDisplayIPAddress 表示用IPアドレス 削除
func (api *InterfaceAPI) DeleteDisplayIPAddress(interfaceID int64) (bool, error) {
var (
method = "DELETE"
uri = fmt.Sprintf("/%s/%d", api.getResourceURL(), interfaceID)
)
return api.modify(method, uri, nil)
}