Skip to content

Commit

Permalink
Update offchain/Cargo.toml
Browse files Browse the repository at this point in the history
Co-authored-by: Gabriel de Quadros Ligneul <[email protected]>
  • Loading branch information
fmoura and gligneul committed Sep 21, 2023
1 parent fbfd4e0 commit 9fce2cb
Show file tree
Hide file tree
Showing 29 changed files with 48 additions and 98 deletions.
1 change: 1 addition & 0 deletions build/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ RUN cargo chef cook --release --recipe-path recipe.json

# Build application
COPY ./offchain/ .
COPY ./.git ../
RUN cargo build --release

#
Expand Down
1 change: 1 addition & 0 deletions grpc-interfaces
Submodule grpc-interfaces added at cba7c3
20 changes: 2 additions & 18 deletions offchain/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 0 additions & 6 deletions offchain/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
members = [
"advance-runner",
"authority-claimer",
"build-info",
"contracts",
"data",
"dispatcher",
Expand Down Expand Up @@ -93,8 +92,3 @@ urlencoding = "2.1"
users = "0.11"
uuid = "1.4"

[profile.release]
strip = true # Automatically strip symbols from the binary.
[workspace.build-dependencies]
built = "0.6"

5 changes: 2 additions & 3 deletions offchain/advance-runner/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,13 @@ name = "advance-runner"
edition.workspace = true
license.workspace = true
version.workspace = true
build = "../build-info/src/build.rs"
build = "../log/src/build.rs"

[[bin]]
name = "cartesi-rollups-advance-runner"
path = "src/main.rs"

[dependencies]
build-info = { path = "../build-info" }
contracts = { path = "../contracts" }
grpc-interfaces = { path = "../grpc-interfaces" }
http-health-check = { path = "../http-health-check" }
Expand Down Expand Up @@ -41,4 +40,4 @@ testcontainers.workspace = true
tracing-subscriber = { workspace = true, features = ["env-filter"] }

[build-dependencies]
built = {workspace = true, features = ["git2"]}
built = { workspace = true, features = ["git2"] }
3 changes: 1 addition & 2 deletions offchain/advance-runner/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,8 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {

info!(?config, "Starting Advance Runner");

build_info::log_build_info(
log::log_build_info(
built_info::PKG_VERSION,
built_info::BUILT_TIME_UTC,
built_info::GIT_HEAD_REF,
built_info::GIT_COMMIT_HASH,
);
Expand Down
5 changes: 2 additions & 3 deletions offchain/authority-claimer/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name = "authority-claimer"
edition.workspace = true
license.workspace = true
version.workspace = true
build = "src/built/build.rs"
build = "../log/src/build.rs"


[[bin]]
Expand All @@ -12,7 +12,6 @@ path = "src/main.rs"
test = false

[dependencies]
build-info = { path = "../build-info" }
http-server = { path = "../http-server" }
log = { path = "../log" }
rollups-events = { path = "../rollups-events" }
Expand All @@ -29,4 +28,4 @@ tracing.workspace = true


[build-dependencies]
built = {workspace = true, features = ["chrono","git2"]}
built = { workspace = true, features = ["git2"] }
5 changes: 0 additions & 5 deletions offchain/authority-claimer/src/built/build.rs

This file was deleted.

3 changes: 1 addition & 2 deletions offchain/authority-claimer/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,8 @@ async fn main() -> Result<(), Box<dyn Error>> {

info!(?config, "Starting Authority Claimer");

build_info::log_build_info(
log::log_build_info(
built_info::PKG_VERSION,
built_info::BUILT_TIME_UTC,
built_info::GIT_HEAD_REF,
built_info::GIT_COMMIT_HASH,
);
Expand Down
10 changes: 0 additions & 10 deletions offchain/build-info/Cargo.toml

This file was deleted.

19 changes: 0 additions & 19 deletions offchain/build-info/src/lib.rs

This file was deleted.

6 changes: 2 additions & 4 deletions offchain/dispatcher/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,13 @@ name = "dispatcher"
edition.workspace = true
license.workspace = true
version.workspace = true
build = "../build-info/src/build.rs"
build = "../log/src/build.rs"

[[bin]]
name = "cartesi-rollups-dispatcher"
path = "src/main.rs"

[dependencies]
build-info = { path = "../build-info" }
contracts = { path = "../contracts" }
http-server = { path = "../http-server" }
log = { path = "../log" }
Expand All @@ -20,7 +19,6 @@ types = { path = "../types" }
async-trait.workspace = true
axum.workspace = true
backoff = { workspace = true, features = ["tokio"] }
built = { workspace = true, features = ["chrono","git2"] }
clap = { workspace = true, features = ["derive", "env"] }
eth-state-client-lib.workspace = true
eth-state-fold-types = { workspace = true, features = ["ethers"] }
Expand Down Expand Up @@ -51,4 +49,4 @@ testcontainers.workspace = true
tracing-test = { workspace = true, features = ["no-env-filter"] }

[build-dependencies]
built = {workspace = true, features = ["chrono","git2"]}
built = { workspace = true, features = ["git2"] }
3 changes: 1 addition & 2 deletions offchain/dispatcher/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,8 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {

info!(?config, "Starting Dispatcher");

build_info::log_build_info(
log::log_build_info(
built_info::PKG_VERSION,
built_info::BUILT_TIME_UTC,
built_info::GIT_HEAD_REF,
built_info::GIT_COMMIT_HASH,
);
Expand Down
6 changes: 2 additions & 4 deletions offchain/graphql-server/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name = "graphql-server"
edition.workspace = true
license.workspace = true
version.workspace = true
build = "../build-info/src/build.rs"
build = "../log/src/build.rs"

[[bin]]
name = "cartesi-rollups-graphql-server"
Expand All @@ -14,14 +14,12 @@ name = "generate-schema"
path = "src/schema/generate_schema.rs"

[dependencies]
build-info = { path = "../build-info" }
http-health-check = { path = "../http-health-check" }
log = { path = "../log" }
rollups-data = { path = "../data" }

actix-cors.workspace = true
actix-web.workspace = true
built = { workspace = true, features = ["chrono","git2"] }
clap = { workspace = true, features = ["derive", "env"] }
hex.workspace = true
juniper.workspace = true
Expand All @@ -39,4 +37,4 @@ serial_test.workspace = true
testcontainers.workspace = true

[build-dependencies]
built = {workspace = true, features = ["chrono","git2"]}
built = { workspace = true, features = ["git2"] }
3 changes: 1 addition & 2 deletions offchain/graphql-server/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,8 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {

info!(?config, "Starting GraphQL Server");

build_info::log_build_info(
log::log_build_info(
built_info::PKG_VERSION,
built_info::BUILT_TIME_UTC,
built_info::GIT_HEAD_REF,
built_info::GIT_COMMIT_HASH,
);
Expand Down
5 changes: 2 additions & 3 deletions offchain/host-runner/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,13 @@ name = "host-runner"
edition.workspace = true
license.workspace = true
version.workspace = true
build = "../build-info/src/build.rs"
build = "../log/src/build.rs"

[[bin]]
name = "cartesi-rollups-host-runner"
path = "src/main.rs"

[dependencies]
build-info = { path = "../build-info" }
grpc-interfaces = { path = "../grpc-interfaces" }
http-health-check = { path = "../http-health-check" }
log = { path = "../log" }
Expand Down Expand Up @@ -40,4 +39,4 @@ serial_test.workspace = true
tracing-test.workspace = true

[build-dependencies]
built = {workspace = true, features = ["chrono","git2"]}
built = { workspace = true, features = ["git2"] }
3 changes: 1 addition & 2 deletions offchain/host-runner/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,8 @@ async fn main() {

info!(?config, "Starting Host Runner");

build_info::log_build_info(
log::log_build_info(
built_info::PKG_VERSION,
built_info::BUILT_TIME_UTC,
built_info::GIT_HEAD_REF,
built_info::GIT_COMMIT_HASH,
);
Expand Down
3 changes: 1 addition & 2 deletions offchain/indexer/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,14 @@ name = "indexer"
edition.workspace = true
license.workspace = true
version.workspace = true
build = "../build-info/src/build.rs"
build = "../log/src/build.rs"

[[bin]]
name = "cartesi-rollups-indexer"
path = "src/main.rs"
test = false

[dependencies]
build-info = { path = "../build-info" }
http-health-check = { path = "../http-health-check" }
log = { path = "../log" }
rollups-data = { path = "../data" }
Expand Down
3 changes: 1 addition & 2 deletions offchain/indexer/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,8 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {

info!(?config, "Starting Indexer");

build_info::log_build_info(
log::log_build_info(
built_info::PKG_VERSION,
built_info::BUILT_TIME_UTC,
built_info::GIT_HEAD_REF,
built_info::GIT_COMMIT_HASH,
);
Expand Down
2 changes: 1 addition & 1 deletion offchain/inspect-server/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,14 @@ name = "inspect-server"
edition.workspace = true
license.workspace = true
version.workspace = true
build = "../log/src/build.rs"

[[bin]]
name = "cartesi-rollups-inspect-server"
path = "src/main.rs"

[dependencies]
grpc-interfaces = { path = "../grpc-interfaces" }
build-info = { path = "../build-info" }
http-health-check = { path = "../http-health-check" }
log = { path = "../log" }

Expand Down
Loading

0 comments on commit 9fce2cb

Please sign in to comment.