mirror of
https://github.com/rancher/os.git
synced 2025-09-04 08:14:21 +00:00
gofmt
This commit is contained in:
@@ -65,7 +65,7 @@ func osRollback(c *cli.Context) {
|
||||
|
||||
fileReader := bufio.NewScanner(file)
|
||||
line := " "
|
||||
for ; line[len(line)-1:] != "*"; {
|
||||
for line[len(line)-1:] != "*" {
|
||||
if !fileReader.Scan() {
|
||||
log.Error("Current version not indicated in " + osVersionsFile)
|
||||
}
|
||||
@@ -81,7 +81,8 @@ func osRollback(c *cli.Context) {
|
||||
}
|
||||
|
||||
func osMetaDataGet(c *cli.Context) {
|
||||
osChannel, ok := getChannelUrl("meta"); if !ok {
|
||||
osChannel, ok := getChannelUrl("meta")
|
||||
if !ok {
|
||||
log.Fatal("unrecognized channel meta")
|
||||
}
|
||||
resp, err := http.Get(osChannel)
|
||||
@@ -161,7 +162,8 @@ func getLatestImage(channel string) (string, error) {
|
||||
} else {
|
||||
pivot = channel
|
||||
}
|
||||
osChannel, ok := getChannelUrl(pivot); if !ok {
|
||||
osChannel, ok := getChannelUrl(pivot)
|
||||
if !ok {
|
||||
return "", errors.New("unrecognized channel " + pivot)
|
||||
}
|
||||
resp, err := http.Get(osChannel)
|
||||
@@ -191,7 +193,6 @@ func getChannelUrl(channel string) (string, bool) {
|
||||
"meta": "",
|
||||
}
|
||||
}
|
||||
channel, ok := osChannels[channel];
|
||||
channel, ok := osChannels[channel]
|
||||
return channel, ok
|
||||
}
|
||||
|
||||
|
@@ -100,7 +100,6 @@ func tlsConfCreate(c *cli.Context) {
|
||||
serverKeyPath = "client-key.pem"
|
||||
}
|
||||
|
||||
|
||||
serverCertPath = filepath.Join(outDir, serverCertPath)
|
||||
serverKeyPath = filepath.Join(outDir, serverKeyPath)
|
||||
|
||||
|
@@ -8,8 +8,8 @@ import (
|
||||
"strings"
|
||||
"syscall"
|
||||
|
||||
"github.com/fsouza/go-dockerclient"
|
||||
log "github.com/Sirupsen/logrus"
|
||||
"github.com/fsouza/go-dockerclient"
|
||||
)
|
||||
|
||||
const (
|
||||
|
Reference in New Issue
Block a user