0
votes

For one of our customer, who is using Spring Boot version 2.0.0 Release, we have Spring cloud config server with native settings. For local development, we want to disable spring cloud config server so that other spring boot micro-services can use application-local.yml settings.

I tried below options but its not working

  1. Setting spring.cloud.config.enabled=false in bootstrap.yml file
  2. Setting -Dspring.profiles.active="local"

When I run the micro-services, it is still looking for config server. Any inputs.

Can not remove the dependency of config-starter reference in gradle file as a workaround

2

2 Answers

0
votes

These are the configurations that worked for me. I'm using Eureka service to find where the config server is.

spring:
  cloud:
    config:
      enabled: false
      discovery:
        enabled: false

eureka:
  client:
    enabled: false
0
votes

to run the local service without loading props from any remote config server you need to disable the bootstrap file and config.

resources/bootstrap.yml --> resources/application.yml 

with this springboot will load your application.yml by default.