diff --git a/controller/service.go b/controller/service.go index b3abed8..b960413 100644 --- a/controller/service.go +++ b/controller/service.go @@ -76,6 +76,11 @@ func serviceDetail(ctx web.Context) error { return err } + // redirect if name is service id + if name != service.Spec.Name { + return ctx.Redirect("/service/" + service.Spec.Name + "/detail") + } + info := model.NewServiceDetailInfo(service) for _, vip := range service.Endpoint.VirtualIPs { n, e := docker.NetworkInspect(vip.NetworkID) diff --git a/views/task/detail.jet b/views/task/detail.jet index 8492eba..2e47d1d 100644 --- a/views/task/detail.jet +++ b/views/task/detail.jet @@ -35,8 +35,10 @@
ID
{{ .Task.ID }}
+
Service ID
+
{{ .Task.ServiceID }}
{{ if .Task.Status.ContainerStatus.ContainerID }} -
ContainerID
+
Container ID
{{ .Task.Status.ContainerStatus.ContainerID }}
{{ end }} {{ if .Task.Status.ContainerStatus.PID }}