Add customer api module for demo

This commit is contained in:
Sambo Chea 2021-01-28 13:22:46 +07:00
parent eedeb3abfa
commit 2a83907be1
4 changed files with 15 additions and 3 deletions

View File

@ -17,3 +17,11 @@ dependencies {
tasks.withType<Test> {
useJUnitPlatform()
}
tasks.withType<Jar> {
enabled = true
}
tasks.withType<org.springframework.boot.gradle.tasks.bundling.BootJar> {
enabled = false
}

View File

@ -7,6 +7,7 @@ plugins {
dependencies {
api(project(":lib"))
api(project(":customer-api"))
implementation("org.springframework.boot:spring-boot-starter-web")
implementation("com.fasterxml.jackson.module:jackson-module-kotlin")

View File

@ -2,12 +2,15 @@ package com.example.demo
import com.example.lib.MyLib
import com.example.lib.MyUtils
import org.springframework.beans.factory.annotation.Autowired
import org.springframework.boot.CommandLineRunner
import org.springframework.boot.autoconfigure.SpringBootApplication
import org.springframework.boot.runApplication
@SpringBootApplication
class DemoApplication : CommandLineRunner {
@SpringBootApplication (scanBasePackages = ["com.example.customerapi"])
class DemoApplication @Autowired constructor(
//customerRepository: CustomerRepository,
) : CommandLineRunner {
override fun run(vararg args: String?) {
MyLib.doOnMe()

View File

@ -1 +1 @@
spring.data.mongodb.uri=mongodb://192.168.0.202:27017/db-customer-api