fixing scheduling process
This commit is contained in:
parent
b40879d8aa
commit
b87b6c9eeb
models
out/docs/UML/plantuml/diagram_object_models
services
@ -49,7 +49,5 @@ func NewLink(src ResourceObject, srcId string, dst ResourceObject, dstId string)
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
// So far only computing components expect the ID of the DC in their attributes
|
|
||||||
// func (l *Link) AddLinkToDataCenter(component models.ComputingModel) {
|
|
||||||
// }
|
|
||||||
|
|
||||||
|
Binary file not shown.
Before ![]() (image error) Size: 345 KiB |
@ -3,6 +3,8 @@ package services
|
|||||||
import (
|
import (
|
||||||
"os"
|
"os"
|
||||||
|
|
||||||
|
conf "cloud.o-forge.io/core/oc-catalog/conf"
|
||||||
|
|
||||||
SelfAPI "cloud.o-forge.io/core/oc-catalog/selfapi"
|
SelfAPI "cloud.o-forge.io/core/oc-catalog/selfapi"
|
||||||
"github.com/beego/beego/v2/core/logs"
|
"github.com/beego/beego/v2/core/logs"
|
||||||
beego "github.com/beego/beego/v2/server/web"
|
beego "github.com/beego/beego/v2/server/web"
|
||||||
@ -14,6 +16,7 @@ func GetSelfAPI(host string) *SelfAPI.APIClient {
|
|||||||
return SelfAPI.NewAPIClient(&SelfAPI.Configuration{BasePath: "http://" + host + "/v1"})
|
return SelfAPI.NewAPIClient(&SelfAPI.Configuration{BasePath: "http://" + host + "/v1"})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Need to understand why there are so many different DC name
|
||||||
func Discoveryinit() {
|
func Discoveryinit() {
|
||||||
|
|
||||||
dcNameOS := os.Getenv("DOCKER_DCNAME")
|
dcNameOS := os.Getenv("DOCKER_DCNAME")
|
||||||
@ -32,4 +35,7 @@ func Discoveryinit() {
|
|||||||
DC_NAME = "DC_DEFAULT"
|
DC_NAME = "DC_DEFAULT"
|
||||||
logs.Warning("Default DC name is used")
|
logs.Warning("Default DC name is used")
|
||||||
|
|
||||||
|
// Quickfix for scheduling
|
||||||
|
DC_NAME = conf.GetConfig().DCNAME
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -5,7 +5,7 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
func Init() {
|
func Init() {
|
||||||
// Discoveryinit() //First init DC name
|
Discoveryinit() //First init DC name
|
||||||
|
|
||||||
// var DBpoint string
|
// var DBpoint string
|
||||||
// var err error
|
// var err error
|
||||||
|
Loading…
Reference in New Issue
Block a user