Update 'api/src/main/kotlin/com/cubetiqs/web/config/OpenApiDocConfig.kt'

This commit is contained in:
Sambo Chea 2021-12-24 10:43:28 +07:00
parent a2acf8c411
commit e1c4b424cd

View File

@ -10,6 +10,8 @@ import org.springdoc.core.GroupedOpenApi
import org.springframework.beans.factory.annotation.Autowired import org.springframework.beans.factory.annotation.Autowired
import org.springframework.context.annotation.Bean import org.springframework.context.annotation.Bean
import org.springframework.context.annotation.Configuration import org.springframework.context.annotation.Configuration
import io.swagger.v3.oas.annotations.OpenAPIDefinition
import io.swagger.v3.oas.annotations.servers.Server
@Configuration @Configuration
@SecurityScheme( @SecurityScheme(
@ -18,6 +20,11 @@ import org.springframework.context.annotation.Configuration
scheme = "bearer", scheme = "bearer",
bearerFormat = "JWT", bearerFormat = "JWT",
) )
@OpenAPIDefinition(
servers = [
Server(url = "/")
],
)
class OpenApiDocConfig @Autowired constructor( class OpenApiDocConfig @Autowired constructor(
val appProperties: AppProperties, val appProperties: AppProperties,
) { ) {