sup has a Doobie module:

libraryDependencies += "com.kubukoz" %% "sup-doobie" % "0.6.0"

Imports:

import sup._, sup.modules.doobie._

What’s included

connectionCheck

You can build a connection check out of a doobie Transactor. Let’s create one first:

import doobie._, cats.effect._
// import doobie._
// import cats.effect._

def transactor: Transactor[IO] = ???
// transactor: doobie.Transactor[cats.effect.IO]

And now the health check:

import eu.timepit.refined.auto._
// import eu.timepit.refined.auto._

def doobieCheck = connectionCheck(transactor)(timeoutSeconds = Some(5))
// doobieCheck: sup.HealthCheck[cats.effect.IO,cats.Id]