2021-11-16 18:04:01 +00:00
|
|
|
//go:build !consulent
|
2020-01-29 22:30:38 +00:00
|
|
|
// +build !consulent
|
|
|
|
|
|
|
|
package connect
|
|
|
|
|
|
|
|
import (
|
2021-06-25 21:47:47 +00:00
|
|
|
"fmt"
|
|
|
|
|
2020-01-29 22:30:38 +00:00
|
|
|
"github.com/hashicorp/consul/agent/structs"
|
|
|
|
)
|
|
|
|
|
|
|
|
// GetEnterpriseMeta will synthesize an EnterpriseMeta struct from the SpiffeIDService.
|
|
|
|
// in OSS this just returns an empty (but never nil) struct pointer
|
2021-06-25 21:47:47 +00:00
|
|
|
func (id SpiffeIDService) GetEnterpriseMeta() *structs.EnterpriseMeta {
|
2020-01-29 22:30:38 +00:00
|
|
|
return &structs.EnterpriseMeta{}
|
|
|
|
}
|
2021-06-25 21:47:47 +00:00
|
|
|
|
|
|
|
func (id SpiffeIDService) uriPath() string {
|
|
|
|
return fmt.Sprintf("/ns/%s/dc/%s/svc/%s",
|
|
|
|
id.NamespaceOrDefault(),
|
|
|
|
id.Datacenter,
|
|
|
|
id.Service,
|
|
|
|
)
|
|
|
|
}
|