Skip to content

[BE] application.yml 설정

장영재 edited this page Nov 9, 2024 · 1 revision
spring:
  profiles:
    default: local

  jpa:
    hibernate:
      ddl-auto: none

---
spring:
  config:
    activate:
      on-profile: local

  datasource:
    url: jdbc:mysql://localhost:3306/dibb?useSSL=false&allowPublicKeyRetrieval=true
    driver-class-name: com.mysql.cj.jdbc.Driver
    username: 아이디
    password: 비번

  jpa:
    hibernate:
      ddl-auto: update
    show-sql: true
    properties:
      hibernate:
        format_sql: true
    defer-datasource-initialization: true

  jwt:
    secret: vmfhaltmskdlstkfkdgodyroqkfwkdbalroqkfwkdbalaaaaaaaaaaaaaaaabbbbb

  h2:
    console:
      enabled: true

---
spring:
  config:
    activate:
      on-profile: test

  datasource:
    url: jdbc:h2:mem:~/test
    driver-class-name: org.h2.Driver
    username: sa
    password:

  jpa:
    hibernate:
      ddl-auto: create
    show-sql: true
    properties:
      hibernate:
        format_sql: true

  jwt:
    secret: vmfhaltmskdlstkfkdgodyroqkfwkdbalroqkfwkdbalaaaaaaaaaaaaaaaabbbbb

  sql:
    init:
      mode: never
Clone this wiki locally