1
0
mirror of https://github.com/rancher/os.git synced 2025-09-13 21:51:33 +00:00

Fix error format in cloudinit

This commit is contained in:
niusmallnan
2018-07-30 17:40:58 +08:00
parent 9d3dd8796e
commit f2b09794e4
7 changed files with 8 additions and 8 deletions

View File

@@ -53,7 +53,7 @@ func (ms Service) IsAvailable() bool {
checkURL := ms.Root + ms.IsAvailableCheckPath
_, ms.lastError = ms.Client.Get(checkURL)
if ms.lastError != nil {
log.Errorf("%s: %s (lastError: %s)", "IsAvailable", checkURL, ms.lastError)
log.Errorf("%s: %s (lastError: %v)", "IsAvailable", checkURL, ms.lastError)
}
return (ms.lastError == nil)
}
@@ -63,7 +63,7 @@ func (ms *Service) Finish() error {
}
func (ms *Service) String() string {
return fmt.Sprintf("%s: %s (lastError: %s)", "metadata", ms.UserdataURL(), ms.lastError)
return fmt.Sprintf("%s: %s (lastError: %v)", "metadata", ms.UserdataURL(), ms.lastError)
}
func (ms Service) AvailabilityChanges() bool {