1
0
Fork 0
mirror of https://github.com/moby/moby.git synced 2022-11-09 12:21:53 -05:00

Switching to prod index server

This commit is contained in:
Sam Alba 2013-05-02 15:39:44 -07:00 committed by shin-
parent d985050aeb
commit a372f982c1

View file

@ -15,7 +15,7 @@ import (
const CONFIGFILE = ".dockercfg" const CONFIGFILE = ".dockercfg"
// the registry server we want to login against // the registry server we want to login against
const INDEX_SERVER = "https://indexstaging-docker.dotcloud.com" const INDEX_SERVER = "https://index.docker.io"
type AuthConfig struct { type AuthConfig struct {
Username string `json:"username"` Username string `json:"username"`
@ -131,11 +131,11 @@ func Login(authConfig *AuthConfig) (string, error) {
} }
if reqStatusCode == 201 { if reqStatusCode == 201 {
status = "Account created. Please use the confirmation link we sent"+ status = "Account created. Please use the confirmation link we sent" +
" to your e-mail to activate it.\n" " to your e-mail to activate it.\n"
storeConfig = true storeConfig = true
} else if reqStatusCode == 403 { } else if reqStatusCode == 403 {
return "", fmt.Errorf("Login: Your account hasn't been activated. "+ return "", fmt.Errorf("Login: Your account hasn't been activated. " +
"Please check your e-mail for a confirmation link.") "Please check your e-mail for a confirmation link.")
} else if reqStatusCode == 400 { } else if reqStatusCode == 400 {
if string(reqBody) == "\"Username or email already exists\"" { if string(reqBody) == "\"Username or email already exists\"" {