Skip to content

Commit

Permalink
Merge branch 'up'
Browse files Browse the repository at this point in the history
  • Loading branch information
wangeguo committed Oct 16, 2024
2 parents be2fbe9 + c5eb452 commit 2b944b0
Show file tree
Hide file tree
Showing 10 changed files with 582 additions and 559 deletions.
1,084 changes: 547 additions & 537 deletions Cargo.lock

Large diffs are not rendered by default.

23 changes: 17 additions & 6 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[workspace.package]
version = "0.9.1"
version = "0.9.2"
edition = "2021"
license = "Apache-2.0"
repository = "https://github.com/amphitheatre-app/amphitheatre"
Expand All @@ -22,25 +22,36 @@ members = [
# https://doc.rust-lang.org/cargo/reference/workspaces.html#the-workspacedependencies-table
[workspace.dependencies]
amp-builder = { path = "builder" }
amp-common = { git = "https://github.com/amphitheatre-app/common", tag = "v0.9.1" }
amp-common = { git = "https://github.com/amphitheatre-app/common", tag = "v0.9.3" }
amp-resolver = { path = "resolver" }
amp-resources = { path = "resources" }
amp-workflow = { path = "workflow" }
anyhow = "1.0.89"
async-nats = "0.36.0"
async-nats = "0.37.0"
async-trait = "0.1.83"
clap = { version = "4.5.20", features = ["derive", "env"] }
axum = { version = "0.7.7" }
chrono = "0.4.38"
clap = { version = "4.5.19", features = ["derive", "env"] }
dotenv = "0.15.0"
futures = "0.3.31"
k8s-openapi = { version = "0.22.0", default-features = false, features = ["schemars", "latest"] }
kube = { version = "0.93.1", default-features = false, features = ["runtime", "derive", "rustls-tls"] }
k8s-metrics = "0.19.0"
k8s-openapi = { version = "0.23.0", default-features = false, features = ["schemars", "latest"] }
kube = { version = "0.96.0", default-features = false, features = ["runtime", "derive", "rustls-tls"] }
lazy_static = "1.5.0"
serde = { version = "1.0.210", features = ["derive"] }
serde_json = "1.0.128"
serde_yaml = "0.9.34+deprecated"
sha2 = "0.10.8"
tar = "0.4.42"
tempfile = "3.13.0"
thiserror = "1.0.64"
tokio = { version = "1.40.0", features = ["full"] }
tokio-stream = "0.1"
toml = "0.8.15"
tower-http = { version = "0.6.1", features = ["full"] }
tracing = "0.1.40"
tracing-subscriber = { version = "0.3.18", features = ["env-filter"] }
url = "2.5.2"
utoipa = { version = "5.0.0", features = ["axum_extras", "uuid", "chrono", "macros"] }
utoipa-swagger-ui = { version = "8.0.0", features = ["axum", "reqwest"] }
uuid = { version = "1.10.0", features = ["serde", "v4", "fast-rng", "macro-diagnostics"] }
12 changes: 6 additions & 6 deletions apiserver/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ amp-common.workspace = true
amp-resources.workspace = true
anyhow.workspace = true
async-nats.workspace = true
axum = { version = "0.7.7" }
axum.workspace = true
clap.workspace = true
dotenv.workspace = true
futures.workspace = true
Expand All @@ -26,11 +26,11 @@ kube.workspace = true
serde_json.workspace = true
serde.workspace = true
thiserror.workspace = true
tokio-stream = "0.1"
tokio-stream.workspace = true
tokio.workspace = true
tower-http = { version = "0.6.1", features = ["full"] }
tower-http.workspace = true
tracing-subscriber.workspace = true
tracing.workspace = true
utoipa = { version = "4.1.0", features = ["axum_extras", "uuid", "chrono"] }
utoipa-swagger-ui = { version = "7.1.0", features = ["axum", "reqwest"] }
uuid = { version = "1.10.0", features = ["serde", "v4", "fast-rng", "macro-diagnostics"] }
utoipa-swagger-ui.workspace = true
utoipa.workspace = true
uuid.workspace = true
6 changes: 3 additions & 3 deletions apiserver/src/handlers/actor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,19 +15,19 @@
use std::convert::Infallible;
use std::sync::Arc;

use amp_common::sync::Synchronization;
use axum::extract::{Path, State};
use axum::http::StatusCode;
use axum::response::sse::{Event, KeepAlive};
use axum::response::{IntoResponse, Sse};
use axum::Json;

use futures::{Stream, StreamExt};
use tokio_stream::wrappers::ReceiverStream;

use tracing::info;
use uuid::Uuid;

use amp_common::resource::ActorSpec;
use amp_common::sync::Synchronization;

use super::Result;
use crate::context::Context;
use crate::errors::ApiError;
Expand Down
2 changes: 2 additions & 0 deletions apiserver/src/handlers/playbook.rs
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ use kube::Api;
use tokio_stream::StreamExt as _;
use uuid::Uuid;

use amp_common::resource::PlaybookSpec;

use super::Result;
use crate::context::Context;
use crate::requests::playbook::{CreatePlaybookRequest, UpdatePlaybookRequest};
Expand Down
2 changes: 1 addition & 1 deletion controllers/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ amp-resources.workspace = true
amp-workflow.workspace = true
anyhow.workspace = true
async-nats.workspace = true
chrono.workspace = true
clap.workspace = true
dotenv.workspace = true
futures.workspace = true
Expand All @@ -24,4 +25,3 @@ tokio.workspace = true
toml.workspace = true
tracing-subscriber.workspace = true
tracing.workspace = true
chrono = "0.4.38"
2 changes: 1 addition & 1 deletion crdgen/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,4 @@ serde_yaml.workspace = true
serde.workspace = true

[dev-dependencies]
tempfile = "3.13.0"
tempfile.workspace = true
4 changes: 2 additions & 2 deletions resources/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,13 @@ description = "K8s resources manager for the Amphitheatre platform"
[dependencies]
amp-common.workspace = true
anyhow.workspace = true
k8s-metrics = "0.18.0"
k8s-metrics.workspace = true
k8s-openapi.workspace = true
kube.workspace = true
lazy_static.workspace = true
serde_json.workspace = true
serde.workspace = true
sha2 = "0.10.8"
sha2.workspace = true
thiserror.workspace = true
tokio.workspace = true
toml.workspace = true
Expand Down
4 changes: 2 additions & 2 deletions resources/src/service_account.rs
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ pub async fn patch(

let mut image_pull_secrets = account.image_pull_secrets.map_or(vec![], |v| v);
let image_pull_secret_names: HashSet<String> =
HashSet::from_iter(image_pull_secrets.iter().map(|s| s.name.clone().unwrap()));
HashSet::from_iter(image_pull_secrets.iter().map(|s| s.name.clone()));

for secret in new_secrets {
let secret_name = secret.name_any();
Expand All @@ -50,7 +50,7 @@ pub async fn patch(

// Append to original image pull secrets.
if append_to_image_pull_secret && !image_pull_secret_names.contains(&secret_name) {
image_pull_secrets.push(LocalObjectReference { name: Some(secret_name.clone()) });
image_pull_secrets.push(LocalObjectReference { name: secret_name.clone() });
}
}

Expand Down
2 changes: 1 addition & 1 deletion syncer/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ clap.workspace = true
dotenv.workspace = true
futures.workspace = true
serde_json.workspace = true
tar = "0.4.42"
tar.workspace = true
tokio.workspace = true
tracing-subscriber.workspace = true
tracing.workspace = true

0 comments on commit 2b944b0

Please sign in to comment.