springBoot關閉

pom文件linux

<dependency>
  <groupId>org.springframework.boot</groupId>
  <artifactId>spring-boot-starter-actuator</artifactId>
</dependency>

application.ymlspring

endpoints:
   shutdown:
    enabled: true   #啓用shutdown
    sensitive: false

linux命令json

curl -X POST host:port/shutdown
相關文章
相關標籤/搜索