我在配置尤里卡副本时遇到问题:
尤里卡服务:
@EnableEurekaServer
@SpringBootApplication
public class DiscoveryService {
public static void main(String[] args) {
SpringApplication.run(DiscoveryService.class, args);
}
}
Run Code Online (Sandbox Code Playgroud)
bootstrap.properties
spring.application.name=discovery
spring.cloud.config.uri=http://localhost:8888
Run Code Online (Sandbox Code Playgroud)
我还有两个 yml 文件
对于在 8761 上运行的服务器 1
eureka.client.serviceUrl.defaultZone:http://localhost:8762/eureka/
eureka.client.registerWithEureka:false
eureka.client.fetchRegistry:false
Run Code Online (Sandbox Code Playgroud)
对于在 8762 上运行的服务器 2
eureka.client.serviceUrl.defaultZone:http://localhost:8761/eureka/
eureka.client.registerWithEureka:false
eureka.client.fetchRegistry:false
Run Code Online (Sandbox Code Playgroud)
我可以输入两个仪表板,但我看到两个实例都有:
registered-replicas http://localhost:8761/eureka/
unavailable-replicas http://localhost:8761/eureka/,
available-replicas
Run Code Online (Sandbox Code Playgroud)
这是为什么 ?
我一直试图关闭kubernetes集群,但我无法做到这一点.
当我输入
kubectl cluster-info
Run Code Online (Sandbox Code Playgroud)
我可以看到我的群集仍在运行.
我试过像运行脚本这样的命令
kube-down.sh
Run Code Online (Sandbox Code Playgroud)
但它不起作用.
我删除了所有播客.我怎么能把它关掉?