-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.sbt
181 lines (171 loc) · 9.67 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
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
val catsParseVersion = "1.1.0"
val catsTimeVersion = "0.5.1"
val circeVersion = "0.14.10"
val circeRefinedVersion = "0.15.1"
val cirisVersion = "3.7.0"
val clueVersion = "0.40.0"
val declineVersion = "2.5.0"
val disciplineMunitVersion = "1.0.9"
val flywayVersion = "9.20.0"
val fs2AwsVersion = "6.1.3"
val fs2Version = "3.11.0"
val grackleVersion = "0.22.0"
val http4sBlazeVersion = "0.23.17"
val http4sEmberVersion = "0.23.30"
val http4sJdkHttpClientVersion = "0.9.2"
val jwtVersion = "5.0.0"
val logbackVersion = "1.5.16"
val log4catsVersion = "2.7.0"
val lucumaCatalogVersion = "0.48.13"
val lucumaItcVersion = "0.24.4"
val lucumaCoreVersion = "0.113.0"
val lucumaGraphQLRoutesVersion = "0.8.15"
val lucumaSsoVersion = "0.8.0"
val munitVersion = "0.7.29" // check test output if you attempt to update this
val munitCatsEffectVersion = "1.0.7" // check test output if you attempt to update this
val munitDisciplineVersion = "1.0.9" // check test output if you attempt to update this
val natchezHttp4sVersion = "0.6.0"
val natchezVersion = "0.3.7"
val paigesVersion = "0.4.4"
val postgresVersion = "42.7.4"
val pprintVersion = "0.9.0"
val skunkVersion = "0.6.4"
val testcontainersScalaVersion = "0.40.14" // check test output if you attempt to update this
ThisBuild / tlBaseVersion := "0.18"
ThisBuild / scalaVersion := "3.5.1"
ThisBuild / crossScalaVersions := Seq("3.5.1")
ThisBuild / Test / fork := false
ThisBuild / Test / parallelExecution := false
ThisBuild / githubWorkflowSbtCommand := "sbt -v -J-Xmx6g"
ThisBuild / githubWorkflowBuild +=
WorkflowStep.Use(
UseRef.Public("gemini-hlsw", "migration-validator-action", "main"),
name = Some("Validate Migrations"),
params = Map("path" -> "modules/service/src/main/resources/db/migration/"),
cond = Some("github.event_name == 'pull_request'")
)
lazy val schema =
crossProject(JVMPlatform, JSPlatform)
.crossType(CrossType.Pure)
.in(file("modules/schema"))
.settings(
name := "lucuma-odb-schema",
libraryDependencies ++= Seq(
"io.circe" %%% "circe-parser" % circeVersion,
"io.circe" %%% "circe-literal" % circeVersion,
"io.circe" %%% "circe-refined" % circeRefinedVersion,
"io.circe" %%% "circe-testing" % circeVersion % Test,
"edu.gemini" %%% "lucuma-core" % lucumaCoreVersion,
"edu.gemini" %%% "lucuma-core-testkit" % lucumaCoreVersion % Test,
"edu.gemini" %%% "lucuma-sso-frontend-client" % lucumaSsoVersion,
"org.scalameta" %%% "munit" % munitVersion % Test,
"org.scalameta" %%% "munit-scalacheck" % munitVersion % Test,
"org.typelevel" %%% "discipline-munit" % munitDisciplineVersion % Test
)
)
lazy val sequence = project
.in(file("modules/sequence"))
.dependsOn(schema.jvm)
.enablePlugins(NoPublishPlugin)
.settings(
name := "lucuma-odb-sequence",
libraryDependencies ++= Seq(
"edu.gemini" %% "lucuma-itc-client" % lucumaItcVersion,
"edu.gemini" %% "lucuma-itc-testkit" % lucumaItcVersion % Test,
"org.scalameta" %% "munit" % munitVersion % Test,
"org.scalameta" %% "munit-scalacheck" % munitVersion % Test,
"org.typelevel" %% "discipline-munit" % munitDisciplineVersion % Test
)
)
lazy val smartgcal = project
.in(file("modules/smartgcal"))
.enablePlugins(NoPublishPlugin)
.settings(
name := "lucuma-odb-smartgcal",
libraryDependencies ++= Seq(
"org.typelevel" %% "cats-parse" % catsParseVersion,
"co.fs2" %% "fs2-core" % fs2Version,
"co.fs2" %% "fs2-io" % fs2Version,
"edu.gemini" %% "lucuma-core" % lucumaCoreVersion,
"edu.gemini" %% "lucuma-core-testkit" % lucumaCoreVersion % Test,
"org.scalameta" %% "munit" % munitVersion % Test,
"org.scalameta" %% "munit-scalacheck" % munitVersion % Test,
"org.typelevel" %% "discipline-munit" % munitDisciplineVersion % Test
)
)
lazy val service = project
.in(file("modules/service"))
.dependsOn(phase0, sequence, smartgcal)
.enablePlugins(NoPublishPlugin, JavaAppPackaging)
.settings(
name := "lucuma-odb-service",
projectDependencyArtifacts := (Compile / dependencyClasspathAsJars).value,
libraryDependencies ++= Seq(
"ch.qos.logback" % "logback-classic" % logbackVersion,
"com.monovore" %% "decline-effect" % declineVersion,
"com.monovore" %% "decline" % declineVersion,
"io.laserdisc" %% "fs2-aws-s3" % fs2AwsVersion,
"org.typelevel" %% "grackle-skunk" % grackleVersion,
"edu.gemini" %% "lucuma-catalog" % lucumaCatalogVersion,
"edu.gemini" %% "lucuma-ags" % lucumaCatalogVersion,
"edu.gemini" %% "lucuma-graphql-routes" % lucumaGraphQLRoutesVersion,
"edu.gemini" %% "lucuma-sso-backend-client" % lucumaSsoVersion,
"is.cir" %% "ciris" % cirisVersion,
"is.cir" %% "ciris-refined" % cirisVersion,
"org.flywaydb" % "flyway-core" % flywayVersion,
"org.http4s" %% "http4s-jdk-http-client" % http4sJdkHttpClientVersion,
"org.http4s" %% "http4s-blaze-server" % http4sBlazeVersion,
"org.http4s" %% "http4s-ember-client" % http4sEmberVersion,
"org.postgresql" % "postgresql" % postgresVersion,
"org.tpolecat" %% "natchez-honeycomb" % natchezVersion,
"org.tpolecat" %% "natchez-http4s" % natchezHttp4sVersion,
"org.tpolecat" %% "natchez-log" % natchezVersion,
"org.tpolecat" %% "skunk-core" % skunkVersion,
"org.tpolecat" %% "skunk-circe" % skunkVersion,
"com.lihaoyi" %% "pprint" % pprintVersion,
"com.dimafeng" %% "testcontainers-scala-munit" % testcontainersScalaVersion % Test,
"com.dimafeng" %% "testcontainers-scala-localstack-v2" % testcontainersScalaVersion % Test,
"com.dimafeng" %% "testcontainers-scala-postgresql" % testcontainersScalaVersion % Test,
// testcontainers-scala-localstack-v2 requires both v1 and v2 of the aws sdk
"io.circe" %% "circe-testing" % circeVersion % Test,
"com.amazonaws" % "aws-java-sdk-core" % "1.12.780" % Test,
"edu.gemini" %% "clue-http4s" % clueVersion % Test,
"org.scalameta" %% "munit" % munitVersion % Test,
"org.scalameta" %% "munit-scalacheck" % munitVersion % Test,
"org.typelevel" %% "discipline-munit" % munitDisciplineVersion % Test,
"edu.gemini" %% "lucuma-catalog-testkit" % lucumaCatalogVersion % Test,
"edu.gemini" %% "lucuma-core-testkit" % lucumaCoreVersion % Test,
"org.typelevel" %% "cats-time" % catsTimeVersion,
"org.typelevel" %% "log4cats-slf4j" % log4catsVersion,
"org.typelevel" %% "munit-cats-effect-3" % munitCatsEffectVersion % Test,
"org.typelevel" %% "paiges-core" % paigesVersion,
"com.github.vertical-blank" % "sql-formatter" % "2.0.5"
),
reStart / envVars += "PORT" -> "8082",
reStartArgs += "serve"
)
lazy val calibrations = project
.in(file("modules/calibrations"))
.dependsOn(service)
.enablePlugins(NoPublishPlugin, JavaAppPackaging)
.settings(
name := "calibrations-service",
projectDependencyArtifacts := (Compile / dependencyClasspathAsJars).value,
reStart / envVars += "PORT" -> "8082"
)
lazy val phase0 = project
.in(file("modules/phase0"))
.enablePlugins(NoPublishPlugin)
.settings(
name := "lucuma-odb-phase0",
libraryDependencies ++= Seq(
"org.typelevel" %% "cats-parse" % catsParseVersion,
"co.fs2" %% "fs2-core" % fs2Version,
"co.fs2" %% "fs2-io" % fs2Version,
"edu.gemini" %% "lucuma-core" % lucumaCoreVersion,
"edu.gemini" %% "lucuma-core-testkit" % lucumaCoreVersion % Test,
"org.scalameta" %% "munit" % munitVersion % Test,
"org.scalameta" %% "munit-scalacheck" % munitVersion % Test,
"org.typelevel" %% "discipline-munit" % munitDisciplineVersion % Test
)
)