-
Notifications
You must be signed in to change notification settings - Fork 6
/
build.sbt
103 lines (92 loc) · 2.81 KB
/
build.sbt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
organization in ThisBuild := "be.yannickdeturck"
version in ThisBuild := "1.0-SNAPSHOT"
// the Scala version that will be used for cross-compiled libraries
scalaVersion in ThisBuild := "2.12.4"
val playJsonDerivedCodecs = "org.julienrf" %% "play-json-derived-codecs" % "4.0.0"
val macwire = "com.softwaremill.macwire" %% "macros" % "2.2.5" % "provided"
val scalaTest = "org.scalatest" %% "scalatest" % "3.0.1" % Test
val cassandraDriverExtras = "com.datastax.cassandra" % "cassandra-driver-extras" % "3.0.0" // Adds extra codecs
lazy val `lagom-shop-scala` = (project in file("."))
.aggregate(itemApi, itemImpl,
frontend)
.settings(commonSettings: _*)
lazy val common = (project in file("common"))
.settings(commonSettings: _*)
.settings(
version := "1.0-SNAPSHOT",
libraryDependencies ++= Seq(
lagomScaladslApi,
lagomScaladslServer % Optional,
playJsonDerivedCodecs,
scalaTest
)
)
lazy val itemApi = (project in file("item-api"))
.dependsOn(common)
.settings(commonSettings: _*)
.settings(
libraryDependencies ++= Seq(
lagomScaladslApi,
playJsonDerivedCodecs
)
)
lazy val itemImpl = (project in file("item-impl"))
.dependsOn(itemApi)
.settings(commonSettings: _*)
.enablePlugins(LagomScala, SbtReactiveAppPlugin)
.settings(
libraryDependencies ++= Seq(
lagomScaladslPersistenceCassandra,
lagomScaladslTestKit,
lagomScaladslKafkaBroker,
lagomScaladslPubSub,
cassandraDriverExtras,
macwire,
scalaTest
)
)
.settings(lagomForkedTestSettings: _*)
lazy val orderApi = (project in file("order-api"))
.dependsOn(common)
.settings(commonSettings: _*)
.settings(
libraryDependencies ++= Seq(
lagomScaladslApi,
playJsonDerivedCodecs
)
)
lazy val orderImpl = (project in file("order-impl"))
.dependsOn(orderApi, itemApi)
.settings(commonSettings: _*)
.enablePlugins(LagomScala, SbtReactiveAppPlugin)
.settings(
libraryDependencies ++= Seq(
lagomScaladslPersistenceCassandra,
lagomScaladslTestKit,
lagomScaladslKafkaBroker,
cassandraDriverExtras,
macwire,
scalaTest
)
)
.settings(lagomForkedTestSettings: _*)
lazy val frontend = (project in file("frontend"))
.dependsOn(itemApi, orderApi)
.settings(commonSettings: _*)
.enablePlugins(PlayScala && LagomPlay, SbtReactiveAppPlugin)
.settings(
version := "1.0-SNAPSHOT",
libraryDependencies ++= Seq(
lagomScaladslServer,
lagomScaladslKafkaClient,
macwire,
scalaTest,
"org.webjars" % "foundation" % "6.2.3",
"org.webjars" % "foundation-icon-fonts" % "d596a3cfb3"
),
EclipseKeys.preTasks := Seq(compile in Compile),
httpIngressPaths := Seq("/")
)
def commonSettings: Seq[Setting[_]] = Seq(
)
lagomCassandraCleanOnStart in ThisBuild := true