Skip to content

Commit e7c54db

Browse files
committed
Add CONFIG_CENTER_ENABLED environment variable mapping
1 parent 2338b10 commit e7c54db

File tree

3 files changed

+5
-0
lines changed

3 files changed

+5
-0
lines changed
-4 Bytes
Binary file not shown.

pkg/config/config.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ const (
3333
ApplicationLabel = "jmsf.jd.com/app"
3434
EnhanceTypeLabel = "jmsf.jd.com/enhance"
3535
RegisterTypeLabel = "jmsf.jd.com/register"
36+
ConfigureTypeLabel = "jmsf.jd.com/configure"
3637
EnhanceTypeAgent = "agent"
3738
EnhanceTypeSidecar = "sidecar"
3839
SidecarEnhanceLabel = "sidecar.istio.io/inject"

pkg/resource/control.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,10 @@ func GetApplicationEnvironments(labels map[string]string) (map[string]string, er
7474
envMaps["CONFIG_REGISTRY_ENABLED"] = v
7575
}
7676

77+
if v, ok := labels[config.ConfigureTypeLabel]; ok {
78+
envMaps["CONFIG_CENTER_ENABLED"] = v
79+
}
80+
7781
if group, ok := labels[config.ServiceGroupLabel]; ok {
7882
envMaps["APPLICATION_SERVICE_GROUP"] = group
7983
} else {

0 commit comments

Comments
 (0)