SpringBootでH2の管理コンソールを使う #springboot

spring:h2:console:enabled をtrueにするだけ。

spring:
  datasource:
    driver-class-name: org.h2.Driver
    url: jdbc:h2:mem:testdb;MODE=MYSQL
    username: sa
    password:
  h2:
    console:
      enabled: true

SpringBoot起動後、下記にアクセスすると利用できる。 http://localhost:8080/h2-console

参考

web-dev.hatenablog.com