Skip to content

Commit

Permalink
Merge pull request #49 from chainbound/constraints-api-v0
Browse files Browse the repository at this point in the history
feat: Constraints API v0
  • Loading branch information
0w3n-d authored Nov 29, 2024
2 parents 4aace5f + abf32f5 commit ac3738e
Show file tree
Hide file tree
Showing 61 changed files with 4,614 additions and 602 deletions.
408 changes: 332 additions & 76 deletions Cargo.lock

Large diffs are not rendered by default.

15 changes: 11 additions & 4 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ members = [
"crates/datastore",
"crates/cmd",
"crates/housekeeper",
"crates/website",
]
resolver = "2"

Expand All @@ -26,18 +27,24 @@ helix-database = { path = "./crates/database" }
helix-datastore = { path = "./crates/datastore" }
helix-housekeeper = { path = "./crates/housekeeper" }
helix-utils = { path = "./crates/utils" }
helix-website = { path = "./crates/website" }

# Async and Networking
async-trait = "0.1"
axum = {version = "0.7.4", features = ["ws"]}
axum = { version = "0.7.4", features = ["ws"] }
dashmap = { version = "5.5.3", features = [] }
futures = "0.3"
hyper = "1.1.0"
http = "1.0.0"
tower = { version = "0.4.13", features = ["full"] }
reqwest = { version = "0.11.23", features = ["json", "native-tls-vendored", "stream", "blocking"] }
reqwest = { version = "0.11.23", features = [
"json",
"native-tls-vendored",
"stream",
"blocking",
] }
tokio = { version = "1.33.0", features = ["full"] }
tokio-stream = {version = "0.1.15", features = ["sync"]}
tokio-stream = { version = "0.1.15", features = ["sync"] }
tower-http = { version = "0.5.1", features = ["limit"] }
url = "2.4"

Expand All @@ -51,7 +58,7 @@ deadpool-redis = { version = "0.12.0", features = ["rt_tokio_1"] }
redis = { version = "0.23.2", features = ["aio", "tokio-comp"] }
tokio-postgres = "0.7.10"
deadpool-postgres = "0.11.0"
refinery = { version = "0.8", features = ["tokio-postgres"]}
refinery = { version = "0.8", features = ["tokio-postgres"] }
bytes = "1.5.0"
chrono = "0.4.19"

Expand Down
17 changes: 8 additions & 9 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ RUN apt install -y clang
RUN apt install -y protobuf-compiler

RUN wget https://github.com/mozilla/sccache/releases/download/v0.3.1/sccache-v0.3.1-x86_64-unknown-linux-musl.tar.gz \
&& tar xzf sccache-v0.3.1-x86_64-unknown-linux-musl.tar.gz \
&& mv sccache-v0.3.1-x86_64-unknown-linux-musl/sccache /usr/local/bin/sccache \
&& chmod +x /usr/local/bin/sccache
&& tar xzf sccache-v0.3.1-x86_64-unknown-linux-musl.tar.gz \
&& mv sccache-v0.3.1-x86_64-unknown-linux-musl/sccache /usr/local/bin/sccache \
&& chmod +x /usr/local/bin/sccache

ARG AWS_ACCESS_KEY_ID
ARG AWS_SECRET_ACCESS_KEY
Expand All @@ -33,13 +33,13 @@ RUN ls -lah /app/${REPO_NAME}
WORKDIR /app/${REPO_NAME}

RUN --mount=type=cache,target=/root/.cargo \
--mount=type=cache,target=/usr/local/cargo/registry \
cargo fetch
--mount=type=cache,target=/usr/local/cargo/registry \
cargo fetch

# Run build
RUN --mount=type=cache,target=/root/.cargo \
--mount=type=cache,target=/usr/local/cargo/registry \
RUSTC_WRAPPER=/usr/local/bin/sccache cargo build -p helix-cmd --release
--mount=type=cache,target=/usr/local/cargo/registry \
RUSTC_WRAPPER=/usr/local/bin/sccache cargo build -p helix-cmd --release

# Copy binary into the workdir
RUN mv /app/$REPO_NAME/target/release/helix-cmd /app/helix-cmd
Expand All @@ -57,5 +57,4 @@ WORKDIR /app
COPY --from=helix /app/helix-cmd* ./

# set the startup command to run your binary
ENTRYPOINT ["/app/helix-cmd"]

ENTRYPOINT ["/app/helix-cmd"]
3 changes: 3 additions & 0 deletions crates/api/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,10 @@ tower = { workspace = true }
futures = { workspace = true }
hyper = { workspace = true }
reqwest = { workspace = true }
reqwest-eventsource = "0.5"
tokio = { workspace = true }
tokio-tungstenite = "0.16"
tokio-stream = { workspace = true }
tower-http = { workspace = true }
url = { workspace = true }
tonic = "0.10"
Expand All @@ -50,6 +52,7 @@ auto_impl.workspace = true
rand = "0.8"
thiserror = { workspace = true }
tracing = { workspace = true }
tracing-subscriber = { workspace = true }
uuid = { workspace = true }
bytes = "1.5"
moka = "0.9"
Expand Down
Loading

0 comments on commit ac3738e

Please sign in to comment.