use fixed port names for runtime k8s

This commit is contained in:
Asim Aslam 2019-12-10 14:05:05 +00:00
parent 8289dbabc4
commit 8da77a3ddc

View File

@ -53,7 +53,7 @@ func NewService(name, version, typ string) *Service {
Type: "ClusterIP",
Selector: Labels,
Ports: []ServicePort{{
name + "-port", 9090, "",
"service-port", 9090, "",
}},
}
@ -107,7 +107,7 @@ func NewDeployment(name, version, typ string) *Deployment {
Env: []EnvVar{env},
Command: []string{"go", "run", "main.go"},
Ports: []ContainerPort{{
Name: name + "-port",
Name: "service-port",
ContainerPort: 8080,
}},
}},