forked from akka/akka-management
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.sbt
154 lines (142 loc) · 5.38 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
import java.nio.file.Paths
// root
lazy val `akka-management-root` = project
.in(file("."))
.settings(unidocSettings)
.enablePlugins(NoPublish)
.disablePlugins(BintrayPlugin)
.aggregate(
`akka-discovery`,
`akka-discovery-dns`,
`akka-discovery-kubernetes-api`,
`akka-discovery-marathon-api`,
`akka-discovery-aws-api`,
`akka-management`,
`cluster-http`,
`cluster-bootstrap`,
docs)
// interfaces and extension for Discovery
lazy val `akka-discovery` = project
.in(file("discovery"))
.enablePlugins(AutomateHeaderPlugin)
.settings(unidocSettings)
.settings(
name := "akka-discovery",
organization := "com.lightbend.akka.discovery",
Dependencies.Discovery
)
// DNS implementation of discovery, default and works well for Kubernetes among other things
lazy val `akka-discovery-dns` = project
.in(file("discovery-dns"))
.enablePlugins(AutomateHeaderPlugin)
.settings(unidocSettings)
.settings(
name := "akka-discovery-dns",
organization := "com.lightbend.akka.discovery",
Dependencies.DiscoveryDns
)
.dependsOn(`akka-discovery`)
// K8s API implementation of discovery, allows formation to work even when readiness/health checks are failing
lazy val `akka-discovery-kubernetes-api` = project
.in(file("discovery-kubernetes-api"))
.enablePlugins(AutomateHeaderPlugin)
.settings(unidocSettings)
.settings(
name := "akka-discovery-kubernetes-api",
organization := "com.lightbend.akka.discovery",
Dependencies.DiscoveryKubernetesApi
)
.dependsOn(`akka-discovery`)
// Marathon API implementation of discovery, allows port discovery and formation to work even when readiness/health checks are failing
lazy val `akka-discovery-marathon-api` = project
.in(file("discovery-marathon-api"))
.enablePlugins(AutomateHeaderPlugin)
.settings(unidocSettings)
.settings(
name := "akka-discovery-marathon-api",
organization := "com.lightbend.akka.discovery",
Dependencies.DiscoveryMarathonApi
)
.dependsOn(`akka-discovery`)
// AWS implementation of discovery
lazy val `akka-discovery-aws-api` = project
.in(file("discovery-aws-api"))
.enablePlugins(AutomateHeaderPlugin)
.settings(unidocSettings)
.settings(
name := "akka-discovery-aws-api",
organization := "com.lightbend.akka.discovery",
Dependencies.DiscoveryAwsApi
)
.dependsOn(`akka-discovery`)
// gathers all enabled routes and serves them (HTTP or otherwise)
lazy val `akka-management` = project
.in(file("management"))
.enablePlugins(AutomateHeaderPlugin)
.settings(unidocSettings)
.settings(
name := "akka-management",
Dependencies.ManagementHttp
)
// cluster management http routes, expose information and operations about the cluster
lazy val `cluster-http` = project
.in(file("cluster-http"))
.enablePlugins(AutomateHeaderPlugin)
.settings(
name := "akka-management-cluster-http",
Dependencies.ClusterHttp
)
.dependsOn(`akka-management`)
// cluster bootstraping
lazy val `cluster-bootstrap` = project
.in(file("cluster-bootstrap"))
.enablePlugins(AutomateHeaderPlugin)
.settings(
name := "akka-management-cluster-bootstrap",
Dependencies.ClusterBootstrap
)
.dependsOn(`akka-management`, `akka-discovery`)
// TODO I was thinking about introducing a module called akka-management-cluster-bootstrap-dns which does not do anything,
// except pull together the 2 modules of cluster bootstrap and akka discovery dns so it's only 1 dependency you need to pick.
// I was thinking it would be nice to have "hello world bootstrap in the smallest number of steps" so that would reduce 2 deps into 1.
// demo of the bootstrap
lazy val `bootstrap-joining-demo-kubernetes-api` = project
.in(file("bootstrap-joining-demo/kubernetes-api"))
.enablePlugins(NoPublish)
.disablePlugins(BintrayPlugin)
.enablePlugins(AutomateHeaderPlugin)
.settings(
name := "akka-management-bootstrap-joining-demo-kubernetes-api",
skip in publish := true,
sources in (Compile, doc) := Seq.empty,
whitesourceIgnore := true
).dependsOn(
`akka-management`,
`cluster-http`,
`akka-discovery-dns`,
`cluster-bootstrap`,
`akka-discovery-kubernetes-api`
)
val unidocTask = sbtunidoc.Plugin.UnidocKeys.unidoc in(ProjectRef(file("."), "akka-management"), Compile)
lazy val docs = project
.in(file("docs"))
.enablePlugins(ParadoxPlugin, NoPublish)
.disablePlugins(BintrayPlugin)
.settings(
name := "Akka Management",
paradoxTheme := Some(builtinParadoxTheme("generic")),
paradox in Compile := (paradox in Compile).dependsOn(unidocTask).value,
paradoxProperties ++= Map(
"version" -> version.value,
"scala.binaryVersion" -> scalaBinaryVersion.value,
"extref.akka-docs.base_url" -> s"http://doc.akka.io/docs/akka/${Dependencies.AkkaVersion}/%s",
"extref.akka-http-docs.base_url" -> s"http://doc.akka.io/docs/akka-http/${Dependencies.AkkaHttpVersion}/%s.html",
"extref.java-api.base_url" -> "https://docs.oracle.com/javase/8/docs/api/index.html?%s.html",
"scaladoc.akka.base_url" -> s"http://doc.akka.io/api/akka/${Dependencies.AkkaVersion}",
"scaladoc.akka.management.http.base_url" -> {
if (isSnapshot.value) Paths.get((target in paradox in Compile).value.getPath).relativize(Paths.get(unidocTask.value.head.getPath)).toString
else s"http://developer.lightbend.com/docs/api/akka-management/${version.value}"
},
"scaladoc.version" -> "2.12.0"
)
)