Skip to content

Commit

Permalink
mx-cloud overhaul
Browse files Browse the repository at this point in the history
  • Loading branch information
oscartbeaumont committed Sep 13, 2024
1 parent 6406236 commit 72a7e36
Show file tree
Hide file tree
Showing 18 changed files with 740 additions and 623 deletions.
179 changes: 94 additions & 85 deletions Cargo.lock

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

13 changes: 7 additions & 6 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,12 @@ specta = { version = "=2.0.0-rc.20", features = [
] }
specta-util = { version = "0.0.7" }
specta-typescript = "0.0.7"

# TODO: Move to crates.io release once available
rspc = { git = "https://github.com/specta-rs/rspc", rev = "56d0230adf541515235add9e12c885222e447167" }
rspc-openapi = { git = "https://github.com/specta-rs/rspc", rev = "56d0230adf541515235add9e12c885222e447167" }
rspc-axum = { git = "https://github.com/specta-rs/rspc", rev = "56d0230adf541515235add9e12c885222e447167" }
mysql_async = { version = "0.34.2", default-features = false, features = [
"default-rustls",
"derive",
"tracing",
"chrono",
] }

[patch.crates-io]
# TODO: This is likely a security risk, will fix it properly once the MVP is out.
Expand All @@ -49,4 +50,4 @@ easy-xml-derive = { git = "https://github.com/oscartbeaumont/easy-xml", rev = "f
refinery-core = { git = "https://github.com/rust-db/refinery", rev = "ff1c5c07c00f196e8ec4f10827ab882db2fd9d14" }

# TODO: This should only be used when using SST Live Lambda!
lambda_runtime = { git = "https://github.com/oscartbeaumont/aws-lambda-rust-runtime", rev = "9d75ac7168dd6869bfa8deb1bc83018830dc617f" }
# lambda_runtime = { git = "https://github.com/oscartbeaumont/aws-lambda-rust-runtime", rev = "9d75ac7168dd6869bfa8deb1bc83018830dc617f" }
8 changes: 6 additions & 2 deletions apps/cloud/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,18 @@ description = "Services for Mattrax's Cloud offering"
version = "0.0.1"
edition = "2021"
publish = false
default-run = "axum"

[dependencies]
mx-manage = { path = "../../crates/mx-manage" }
mx-db = { path = "../../crates/mx-db" }

tracing = { workspace = true }
axum = { workspace = true, features = ["http2", "macros", "ws"] }
serde = { workspace = true, features = ["derive"] }
tokio = { workspace = true }
rspc-axum = { workspace = true }
rspc-openapi = { workspace = true }
serde_json = { workspace = true }
mysql_async = { workspace = true }

openssl = { version = "0.10.66", features = ["vendored"] }

Expand All @@ -24,3 +26,5 @@ tower-http = { version = "0.5.2", features = ["trace"] }
axum-extra = { version = "0.9.3", features = ["cookie"] }
reqwest = "0.12.7"
ms-mdm = { version = "0.0.1", path = "../../crates/ms-mdm" }
base64 = "0.22.1"
cuid2 = "0.1.3"
11 changes: 11 additions & 0 deletions apps/cloud/build.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
use std::process::Command;

fn main() {
let output = Command::new("git")
.args(["rev-parse", "--short", "HEAD"])
.output()
.expect("error getting git hash. Does `git rev-parse --short HEAD` work for you?");
let git_hash = String::from_utf8(output.stdout)
.expect("Error passing output of `git rev-parse --short HEAD`");
println!("cargo:rustc-env=GIT_HASH={git_hash}");
}
Loading

0 comments on commit 72a7e36

Please sign in to comment.