add function to s3
This commit is contained in:
@@ -133,6 +133,18 @@ func (h *Handler) ListNetworkInterfaces(c *gin.Context) {
|
||||
c.JSON(http.StatusOK, gin.H{"interfaces": interfaces})
|
||||
}
|
||||
|
||||
// GetManagementIPAddress returns the management IP address
|
||||
func (h *Handler) GetManagementIPAddress(c *gin.Context) {
|
||||
ip, err := h.service.GetManagementIPAddress(c.Request.Context())
|
||||
if err != nil {
|
||||
h.logger.Error("Failed to get management IP address", "error", err)
|
||||
c.JSON(http.StatusInternalServerError, gin.H{"error": "failed to get management IP address"})
|
||||
return
|
||||
}
|
||||
|
||||
c.JSON(http.StatusOK, gin.H{"ip_address": ip})
|
||||
}
|
||||
|
||||
// SaveNTPSettings saves NTP configuration to the OS
|
||||
func (h *Handler) SaveNTPSettings(c *gin.Context) {
|
||||
var settings NTPSettings
|
||||
|
||||
Reference in New Issue
Block a user