server:
  port: 8084

spring:
  application:
    name: gym-manage-api
  main:
    allow-bean-definition-overriding: true
  cache:
    type: none
  autoconfigure:
    exclude:
      - org.springframework.boot.autoconfigure.cache.CacheAutoConfiguration
  r2dbc:
    url: r2dbc:postgresql://${DB_HOST:localhost}:${DB_PORT:55432}/${DB_NAME:manage_system}
    username: ${DB_USERNAME:postgres}
    password: ${DB_PASSWORD:postgres}
    pool:
      initial-size: 10
      max-size: 50
      max-idle-time: 30m
      max-life-time: 1h
      acquire-timeout: 5s
  datasource:
    url: jdbc:postgresql://${DB_HOST:localhost}:${DB_PORT:55432}/${DB_NAME:manage_system}
    username: ${DB_USERNAME:postgres}
    password: ${DB_PASSWORD:postgres}
    driver-class-name: org.postgresql.Driver
  flyway:
    enabled: true
    locations: classpath:db/migration
    baseline-on-migrate: true
    baseline-version: 0
    validate-on-migrate: true
  security:
    user:
      name: disabled
      password: disabled

management:
  endpoints:
    web:
      exposure:
        include: health,info,metrics,env,loggers
      base-path: /actuator
  endpoint:
    health:
      show-details: always
  metrics:
    tags:
      application: ${spring.application.name}
      environment: ${spring.profiles.active}

logging:
  level:
    cn.novalon.manage: DEBUG
    org.springframework.r2dbc: DEBUG
    cn.novalon.manage.db: DEBUG

jwt:
  secret: ${JWT_SECRET:U2FsdGVkX1+vZ5Y9QmKxL8nN3rP7tW2jH4fG6dA8sB1cE5yN0zX3qV7wM4}
  expiration: ${JWT_EXPIRATION:86400000}

springdoc:
  api-docs:
    path: /api-docs
    enabled: true
  swagger-ui:
    path: /swagger-ui.html
    enabled: true
    tags-sorter: alpha
    operations-sorter: alpha
  show-actuator: false
  default-consumes-media-type: application/json
  default-produces-media-type: application/json
