application.yml
# 激活某个环境配置
spring:
profiles:
active: dev
# 通用配置
server:
servlet:
context-path: /aaa
application-dev.yml
server:
port: 8081
application-test.yml
server:
port: 8082
servlet:
context-path: /bbb
application-prod.yml
server:
port: 8083