generated from navikt/bidrag-stonad
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathBidragGrunnlagLokalNais.kt
24 lines (21 loc) · 1.22 KB
/
BidragGrunnlagLokalNais.kt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
package no.nav.bidrag.grunnlag
import no.nav.security.token.support.spring.api.EnableJwtTokenValidation
import org.springframework.boot.SpringApplication
import org.springframework.boot.actuate.autoconfigure.security.servlet.ManagementWebSecurityAutoConfiguration
import org.springframework.boot.autoconfigure.SpringBootApplication
import org.springframework.boot.autoconfigure.security.servlet.SecurityAutoConfiguration
import org.springframework.context.annotation.ComponentScan
import org.springframework.context.annotation.EnableAspectJAutoProxy
import org.springframework.context.annotation.FilterType
import org.springframework.context.annotation.Profile
@SpringBootApplication(exclude = [SecurityAutoConfiguration::class, ManagementWebSecurityAutoConfiguration::class])
@EnableAspectJAutoProxy
@EnableJwtTokenValidation(ignore = ["org.springdoc", "org.springframework"])
@ComponentScan(excludeFilters = [ComponentScan.Filter(type = FilterType.ASSIGNABLE_TYPE, value = [BidragGrunnlag::class])])
@Profile("lokal-nais")
class BidragGrunnlagLokalNais
fun main(args: Array<String>) {
val app = SpringApplication(BidragGrunnlagLokalNais::class.java)
app.setAdditionalProfiles("lokal-nais", "lokal-nais-secrets")
app.run(*args)
}