Compare commits
6 Commits
akramsbran
...
master
Author | SHA1 | Date |
---|---|---|
Jeff Carr | 19c4932cba | |
Jeff Carr | 96b1951184 | |
Jeff Carr | 4be77889d1 | |
Jeff Carr | b10f647312 | |
Jeff Carr | 40ec27a48b | |
Akram | 92a3739391 |
|
@ -24,8 +24,8 @@ must be installed.
|
|||
# build
|
||||
|
||||
```
|
||||
go get -v -t -u git.wit.com/wit/cloud-control-panel
|
||||
cd ~/go/src/git.wit.com/wit/cloud-control-panel
|
||||
go get -v -t -u git.wit.org/wit/cloud-control-panel
|
||||
cd ~/go/src/git.wit.org/wit/cloud-control-panel
|
||||
go build
|
||||
./cloud-control-panel
|
||||
```
|
||||
|
|
|
@ -2,15 +2,15 @@ package main
|
|||
|
||||
// This should build the control panel correctly on each platform
|
||||
|
||||
// Then, upload the binaries to mirrors.wit.com/cloud/control-panel
|
||||
// Then, upload the binaries to mirrors.wit.org/cloud/control-panel
|
||||
|
||||
import "log"
|
||||
//import "fmt"
|
||||
//import "time"
|
||||
//import "os/user"
|
||||
|
||||
import "git.wit.com/wit/shell"
|
||||
import build "git.wit.com/wit/cloud-control-panel-build"
|
||||
import "git.wit.org/wit/shell"
|
||||
import build "git.wit.org/wit/cloud-control-panel-build"
|
||||
|
||||
var filename string
|
||||
|
||||
|
|
|
@ -20,8 +20,8 @@ import "io/ioutil"
|
|||
import "strings"
|
||||
|
||||
import "github.com/golang/protobuf/jsonpb"
|
||||
import pb "git.wit.com/wit/witProtobuf"
|
||||
import "git.wit.com/wit/shell"
|
||||
import pb "git.wit.org/jcarr/witProtobuf"
|
||||
import "git.wit.org/wit/shell"
|
||||
|
||||
import "github.com/davecgh/go-spew/spew"
|
||||
|
||||
|
@ -66,7 +66,7 @@ var customUsage = func() {
|
|||
fmt.Println("")
|
||||
fmt.Println("EXAMPLES:")
|
||||
fmt.Println("")
|
||||
fmt.Println(os.Args[0] + " --hostname test.hostname.wit.com")
|
||||
fmt.Println(os.Args[0] + " --hostname test.hostname.wit.org")
|
||||
fmt.Println("")
|
||||
}
|
||||
var defaultconfig *bool
|
||||
|
|
|
@ -3,8 +3,8 @@ package main
|
|||
import "log"
|
||||
|
||||
import "github.com/golang/protobuf/proto"
|
||||
import pb "git.wit.com/wit/witProtobuf"
|
||||
import "git.wit.com/wit/gui"
|
||||
import pb "git.wit.org/jcarr/witProtobuf"
|
||||
import "git.wit.org/wit/gui"
|
||||
|
||||
var mychannel chan *pb.Event
|
||||
var currentMessage *pb.Event
|
||||
|
|
|
@ -11,8 +11,8 @@ import "time"
|
|||
import "github.com/gorilla/websocket"
|
||||
|
||||
import "github.com/golang/protobuf/proto"
|
||||
import pb "git.wit.com/wit/witProtobuf"
|
||||
// import "git.wit.com/wit/gui"
|
||||
import pb "git.wit.org/jcarr/witProtobuf"
|
||||
// import "git.wit.org/wit/gui"
|
||||
|
||||
var gorillaConn *websocket.Conn
|
||||
|
||||
|
@ -87,7 +87,7 @@ func closeGorillaConn() {
|
|||
}
|
||||
|
||||
func gorillaDial(hostname string) {
|
||||
// var addr = flag.String("addr", "v000185.testing.com.customers.wprod.wit.com:9000", "http service address")
|
||||
// var addr = flag.String("addr", "v000185.testing.com.customers.wprod.wit.org:9000", "http service address")
|
||||
|
||||
for {
|
||||
u := url.URL{
|
||||
|
|
|
@ -3,8 +3,8 @@ package main
|
|||
import "log"
|
||||
import "fmt"
|
||||
|
||||
import "git.wit.com/wit/gui"
|
||||
import pb "git.wit.com/wit/witProtobuf"
|
||||
import "git.wit.org/wit/gui"
|
||||
import pb "git.wit.org/jcarr/witProtobuf"
|
||||
|
||||
func makeCloudInfoBox(gw *gui.GuiWindow) {
|
||||
log.Println("makeCloudInfoBox() START gw =", gw)
|
||||
|
@ -30,6 +30,9 @@ func makeCloudInfoBox(gw *gui.GuiWindow) {
|
|||
vbox := gui.NewBox(box, gui.Xaxis, fmt.Sprintf("ACCOUNT %d", key))
|
||||
log.Println("account = ", key, a)
|
||||
log.Println("Accounts[key] = ", config.Accounts[key])
|
||||
if config.Accounts[key] == nil {
|
||||
continue;
|
||||
}
|
||||
log.Println("account.Nick = ", config.Accounts[key].Nick)
|
||||
log.Println("account.Username = ", config.Accounts[key].Username)
|
||||
log.Println("account.Token = ", config.Accounts[key].Token)
|
||||
|
@ -100,7 +103,7 @@ func addSubdomainClick(b *gui.GuiButton) {
|
|||
acc.Username = "jcarr@wit.com"
|
||||
acc.Email = "jcarr@wit.com"
|
||||
acc.Password = "badpass"
|
||||
acc.URL = "http://stackapi-api1.stackapi.customers.wprod.wit.com:4000/"
|
||||
acc.URL = "http://stackapi-api1.stackapi.customers.wprod.wit.org:4000/"
|
||||
config.Accounts = append(config.Accounts, acc)
|
||||
|
||||
makeCloudInfoBox(b.Box.Window)
|
||||
|
@ -125,7 +128,7 @@ func generateSubdomain(b *gui.GuiButton) {
|
|||
}
|
||||
// subdomain.SetText("cust00013.wit.dev")
|
||||
|
||||
txt := gui.SetText(b.Box, "SUBDOMAIN", "yourname.customers.wprod.wit.com")
|
||||
txt := gui.SetText(b.Box, "SUBDOMAIN", "yourname.customers.wprod.wit.org")
|
||||
log.Println("generateSubdomain subdomain = ", txt)
|
||||
log.Println("generateSubdomain END")
|
||||
}
|
||||
|
|
|
@ -6,8 +6,8 @@ import "time"
|
|||
// import "runtime"
|
||||
// import "runtime/debug"
|
||||
|
||||
import "git.wit.com/wit/gui"
|
||||
import pb "git.wit.com/wit/witProtobuf"
|
||||
import "git.wit.org/wit/gui"
|
||||
import pb "git.wit.org/jcarr/witProtobuf"
|
||||
// import "github.com/davecgh/go-spew/spew"
|
||||
|
||||
//
|
||||
|
@ -46,7 +46,7 @@ func mainMouseClick(b *gui.GuiButton) {
|
|||
|
||||
if (b == nil) {
|
||||
log.Println("mainMouseClick() BACK IN MAIN CONTROL PANEL CODE (button is nil) WHY DID THIS HAPPEN?")
|
||||
log.Println("THIS IS PROBABLY A BUG IN git.wit.com/gui")
|
||||
log.Println("THIS IS PROBABLY A BUG IN git.wit.org/gui")
|
||||
// gui.ErrorWindow(gw,
|
||||
// "Unknown Mouse Event",
|
||||
// "Error in mainMouseClick()")
|
||||
|
|
|
@ -4,8 +4,8 @@ import "fmt"
|
|||
import "image/color"
|
||||
// import "runtime"
|
||||
|
||||
import pb "git.wit.com/wit/witProtobuf"
|
||||
import "git.wit.com/wit/gui"
|
||||
import pb "git.wit.org/jcarr/witProtobuf"
|
||||
import "git.wit.org/wit/gui"
|
||||
|
||||
var windowsTextVeryLightGrey = color.RGBA{10, 10, 10, 10}
|
||||
var windowsTextBlack = color.RGBA{0, 0, 0, 255}
|
||||
|
|
|
@ -7,13 +7,13 @@ import "runtime"
|
|||
import "os/exec"
|
||||
import "strings"
|
||||
|
||||
import "git.wit.com/wit/gui"
|
||||
import "git.wit.com/wit/shell"
|
||||
// import pb "git.wit.com/wit/witProtobuf"
|
||||
import "git.wit.org/wit/gui"
|
||||
import "git.wit.org/wit/shell"
|
||||
// import pb "git.wit.org/wit/witProtobuf"
|
||||
|
||||
import "github.com/davecgh/go-spew/spew"
|
||||
|
||||
// import pb "git.wit.com/wit/witProtobuf"
|
||||
// import pb "git.wit.org/wit/witProtobuf"
|
||||
|
||||
func debugClick(b *gui.GuiButton) {
|
||||
log.Println("debugClick() START")
|
||||
|
|
|
@ -3,13 +3,13 @@ package main
|
|||
import "log"
|
||||
import "runtime"
|
||||
|
||||
import "git.wit.com/wit/gui"
|
||||
import "git.wit.com/wit/shell"
|
||||
import "git.wit.org/wit/gui"
|
||||
import "git.wit.org/wit/shell"
|
||||
|
||||
import "github.com/andlabs/ui"
|
||||
import _ "github.com/andlabs/ui/winmanifest"
|
||||
|
||||
// import pb "git.wit.com/wit/witProtobuf"
|
||||
// import pb "git.wit.org/wit/witProtobuf"
|
||||
|
||||
func showSplashBox(box *gui.GuiBox) *gui.GuiBox {
|
||||
log.Println("ShowSplashBox() START")
|
||||
|
|
12
gui-vm.go
12
gui-vm.go
|
@ -3,8 +3,8 @@ package main
|
|||
import "log"
|
||||
import "fmt"
|
||||
|
||||
import "git.wit.com/wit/gui"
|
||||
import pb "git.wit.com/wit/witProtobuf"
|
||||
import "git.wit.org/wit/gui"
|
||||
import pb "git.wit.org/jcarr/witProtobuf"
|
||||
|
||||
//
|
||||
// THIS IS THE STANDARD VM DISPLAY TABLE
|
||||
|
@ -139,10 +139,10 @@ func createVmBox(gw *gui.GuiWindow, vm *pb.Event_VM) {
|
|||
box = gui.HardBox(gw, gui.Xaxis, txt)
|
||||
|
||||
// Add hostname entry box
|
||||
gui.MakeEntryVbox(box, "hostname:", vm.Hostname, true, "Hostname")
|
||||
gui.MakeEntryVbox(box, "IPv6:", vm.IPv6, true, "IPv6")
|
||||
gui.MakeEntryVbox(box, "RAM:", fmt.Sprintf("%d",vm.Memory), true, "Memory")
|
||||
gui.MakeEntryVbox(box, "CPU:", fmt.Sprintf("%d",vm.Cpus), true, "Cpus")
|
||||
gui.MakeEntryVbox(box, "hostname:", vm.Hostname, false, "Hostname")
|
||||
gui.MakeEntryVbox(box, "IPv6:", vm.IPv6, false, "IPv6")
|
||||
gui.MakeEntryVbox(box, "RAM:", fmt.Sprintf("%d",vm.Memory), false, "Memory")
|
||||
gui.MakeEntryVbox(box, "CPU:", fmt.Sprintf("%d",vm.Cpus), false, "Cpus")
|
||||
gui.MakeEntryVbox(box, "Disk (GB):", fmt.Sprintf("%d",vm.Disk), true, "Disk")
|
||||
gui.MakeEntryVbox(box, "OS Image:", vm.BaseImage, true, "BaseImage")
|
||||
|
||||
|
|
2
linux.go
2
linux.go
|
@ -13,7 +13,7 @@ import "syscall"
|
|||
// import "time"
|
||||
// import "reflect"
|
||||
|
||||
// import "git.wit.com/wit/shell"
|
||||
// import "git.wit.org/wit/shell"
|
||||
// import "github.com/davecgh/go-spew/spew"
|
||||
|
||||
func handleSignal(err interface{}, ret int) {
|
||||
|
|
6
login.go
6
login.go
|
@ -4,8 +4,8 @@ import "log"
|
|||
import "fmt"
|
||||
import "time"
|
||||
|
||||
import "git.wit.com/wit/gui"
|
||||
import pb "git.wit.com/wit/witProtobuf"
|
||||
import "git.wit.org/wit/gui"
|
||||
import pb "git.wit.org/jcarr/witProtobuf"
|
||||
|
||||
// import "github.com/davecgh/go-spew/spew"
|
||||
|
||||
|
@ -43,7 +43,7 @@ func login(b *gui.GuiButton) {
|
|||
log.Println("\tLOGIN WAS OK!", msg)
|
||||
log.Println("\tLOGIN WAS OK! old button.Account was =", values.Account)
|
||||
log.Println("\tLOGIN WAS OK! currentMessage.Account =", currentMessage.Account)
|
||||
if (values.Account.Id == currentMessage.Account.Id) {
|
||||
if (values.Account.ID == currentMessage.Account.ID) {
|
||||
if (values.Account.Token != currentMessage.Account.Token) {
|
||||
log.Println("\tLOGIN SENT NEW TOKEN")
|
||||
values.Account.Token = currentMessage.Account.Token
|
||||
|
|
16
main.go
16
main.go
|
@ -12,10 +12,10 @@ import "reflect"
|
|||
// this is the king of dns libraries
|
||||
import "github.com/miekg/dns"
|
||||
|
||||
import "git.wit.com/wit/gui"
|
||||
import pb "git.wit.com/wit/witProtobuf"
|
||||
import "git.wit.com/jcarr/dnssecsocket"
|
||||
import "git.wit.com/wit/shell"
|
||||
import "git.wit.org/wit/gui"
|
||||
import pb "git.wit.org/jcarr/witProtobuf"
|
||||
import "git.wit.org/jcarr/dnssecsocket"
|
||||
import "git.wit.org/wit/shell"
|
||||
|
||||
import "github.com/gobuffalo/packr"
|
||||
import "github.com/davecgh/go-spew/spew"
|
||||
|
@ -120,10 +120,10 @@ func main() {
|
|||
initChannel()
|
||||
go processEvents()
|
||||
|
||||
v185AAAA := lookupAAAA("v000185.testing.com.customers.wprod.wit.com")
|
||||
v185AAAA := lookupAAAA("v000185.testing.com.customers.wprod.wit.org")
|
||||
log.Println("v185AAA = ", v185AAAA)
|
||||
go gorillaDial("ccp.wit.com:9000")
|
||||
// go gorillaDial("stackapi-ccp.stackapi.customers.wit.com:9000")
|
||||
go gorillaDial("ccp.wit.org:9000")
|
||||
// go gorillaDial("stackapi-ccp.stackapi.customers.wit.org:9000")
|
||||
go gui.WatchGUI()
|
||||
|
||||
// use this to discover what the OS thinks it's hostname is
|
||||
|
@ -199,7 +199,7 @@ func init() {
|
|||
*/
|
||||
}
|
||||
|
||||
// get's sent the return values and errors from git.wit.com/wit/shell/
|
||||
// get's sent the return values and errors from git.wit.org/wit/shell/
|
||||
func handleShell(err interface{}, ret int) {
|
||||
log.Println("handleShell() shell.Run() END Returned ", ret)
|
||||
errChan <- err
|
||||
|
|
|
@ -1 +1 @@
|
|||
0.6.43
|
||||
0.6.46
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
"height": 600,
|
||||
"accounts": [
|
||||
{
|
||||
"id": 42,
|
||||
"ID": 42,
|
||||
"nick": "Alpha jcarr",
|
||||
"username": "jcarr@wit.com",
|
||||
"email": "jcarr@wit.com",
|
||||
|
@ -14,7 +14,7 @@
|
|||
"domain": "jcarr.customers.wprod.wit.com"
|
||||
},
|
||||
{
|
||||
"id": 44,
|
||||
"ID": 44,
|
||||
"nick": "Alpha alfonso",
|
||||
"username": "alfonso@wit.com",
|
||||
"email": "alfonso@wit.com",
|
||||
|
|
|
@ -9,7 +9,7 @@ import "os"
|
|||
import "time"
|
||||
import "runtime"
|
||||
|
||||
import "git.wit.com/wit/shell"
|
||||
import "git.wit.org/wit/shell"
|
||||
|
||||
// import "github.com/davecgh/go-spew/spew"
|
||||
|
||||
|
@ -19,7 +19,7 @@ func upgrade() {
|
|||
filename = "cloud-control-panel.exe"
|
||||
}
|
||||
|
||||
mirrors := "https://mirrors.wit.com/cloud/control-panel/"
|
||||
mirrors := "https://mirrors.wit.org/cloud/control-panel/"
|
||||
upstreamVERSION := shell.Chomp(shell.Wget(mirrors + "VERSION"))
|
||||
|
||||
dir := "/v" + upstreamVERSION + "/linux/"
|
||||
|
|
|
@ -6,7 +6,7 @@ package main
|
|||
|
||||
import "log"
|
||||
|
||||
// import "git.wit.com/wit/shell"
|
||||
// import "git.wit.org/wit/shell"
|
||||
// import "github.com/davecgh/go-spew/spew"
|
||||
|
||||
func handleSignal(err interface{}, ret int) {
|
||||
|
|
Loading…
Reference in New Issue