Skip to content

Commit 9afe1f8

Browse files
authored
Migrate thing-flinger, overlay-files into a "deploy" crate (#835)
1 parent 6393e31 commit 9afe1f8

File tree

10 files changed

+48
-15
lines changed

10 files changed

+48
-15
lines changed

Cargo.lock

Lines changed: 14 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
[workspace]
22
members = [
33
"common",
4+
"deploy",
45
"gateway",
56
"gateway-client",
67
"gateway-messages",
@@ -29,6 +30,7 @@ members = [
2930

3031
default-members = [
3132
"common",
33+
"deploy",
3234
"gateway",
3335
"gateway-client",
3436
"gateway-messages",

deploy/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
/target

deploy/Cargo.toml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
[package]
2+
name = "omicron-deploy"
3+
description = "Tools for deploying Omicron software to target machines"
4+
version = "0.1.0"
5+
edition = "2021"
6+
license = "MPL-2.0"
7+
8+
[dependencies]
9+
anyhow = "1.0"
10+
crossbeam = "0.8"
11+
omicron-sled-agent = { path = "../sled-agent" }
12+
omicron-package = { path = "../package" }
13+
serde = { version = "1.0", features = [ "derive" ] }
14+
serde_derive = "1.0"
15+
structopt = "0.3"
16+
thiserror = "1.0"
17+
18+
# Disable doc builds by default for our binaries to work around issue
19+
# rust-lang/cargo#8373. These docs would not be very useful anyway.
20+
[[bin]]
21+
name = "sled-agent-overlay-files"
22+
doc = false
23+
24+
[[bin]]
25+
name = "thing-flinger"
26+
doc = false
File renamed without changes.
File renamed without changes.

package/src/bin/thing-flinger.rs renamed to deploy/src/bin/thing-flinger.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -190,16 +190,16 @@ fn do_sync(config: &Config) -> Result<()> {
190190
Ok(())
191191
}
192192

193-
// Build omicron-package and omicron-sled-agent on the builder
193+
// Build omicron-package and omicron-deploy on the builder
194194
//
195-
// We need to build omicron-sled-agent for overlay file generation
195+
// We need to build omicron-deploy for overlay file generation
196196
fn do_build_minimal(config: &Config) -> Result<()> {
197197
let server = &config.servers[&config.builder.server];
198198
let cmd = format!(
199199
"cd {} && cargo build -p {} -p {}",
200200
config.builder.omicron_path.to_string_lossy(),
201201
"omicron-package",
202-
"omicron-sled-agent"
202+
"omicron-deploy"
203203
);
204204
ssh_exec(&server, &cmd, false)
205205
}

package/Cargo.toml

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
[package]
22
name = "omicron-package"
3+
description = "Tools for building and installing Omicron packages"
34
version = "0.1.0"
45
edition = "2021"
56
license = "MPL-2.0"
67

78
[dependencies]
89
anyhow = "1.0"
9-
crossbeam = "0.8"
10-
flate2 = "1.0.22"
1110
futures = "0.3.21"
1211
hex = "0.4.3"
1312
indicatif = { version = "0.16.2", features = ["rayon"] }
@@ -32,7 +31,3 @@ walkdir = "2.3"
3231
[[bin]]
3332
name = "omicron-package"
3433
doc = false
35-
36-
[[bin]]
37-
name = "thing-flinger"
38-
doc = false

sled-agent/Cargo.toml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
[package]
22
name = "omicron-sled-agent"
3+
description = "Services for managing sled-local resources"
34
version = "0.1.0"
45
edition = "2021"
56
license = "MPL-2.0"
@@ -67,7 +68,3 @@ doc = false
6768
[[bin]]
6869
name = "sled-agent"
6970
doc = false
70-
71-
[[bin]]
72-
name = "sled-agent-overlay-files"
73-
doc = false

0 commit comments

Comments
 (0)