Skip to content

Commit

Permalink
Fix compilation warnings and errors
Browse files Browse the repository at this point in the history
  • Loading branch information
L3n41c committed Jan 27, 2025
1 parent d8b7efd commit 3ba8f27
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 7 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
## Added
- Introduced the ability for users to configure lading's sample rate,
configuration option `sample_period_milliseconds` in `lading.yaml`.
- Introduce a `container` generator able to generate an arbitrary number
of docker containers

## [0.25.4]
## Changed
Expand Down
10 changes: 5 additions & 5 deletions examples/lading-container.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
generator:
- container:
repository: ghcr.io/scottopell/randomreader
repository: busybox
tag: latest
args: [ "--buffer-size-mb", "10" ]
args:
- sleep
- infinity

blackhole:
- http:
binding_addr: "0.0.0.0:8080"
blackhole: []
1 change: 1 addition & 0 deletions lading/src/bin/payloadtool.rs
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,7 @@ fn check_generator(config: &lading::generator::Config) -> Result<(), Error> {
}
lading::generator::Inner::ProcessTree(_) => unimplemented!("ProcessTree not supported"),
lading::generator::Inner::ProcFs(_) => unimplemented!("ProcFs not supported"),
lading::generator::Inner::Container(_) => unimplemented!("Container not supported"),
};

Ok(())
Expand Down
3 changes: 1 addition & 2 deletions lading/src/generator/container.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ use bollard::image::CreateImageOptions;
use bollard::secret::ContainerCreateResponse;
use bollard::Docker;
use serde::{Deserialize, Serialize};
use tokio::pin;
use tokio_stream::StreamExt;
use tracing::{info, warn};
use uuid::Uuid;
Expand Down Expand Up @@ -65,7 +64,7 @@ impl Container {
/// Will return an error if config parsing fails or runtime setup fails
/// in the future. For now, always succeeds.
pub fn new(
general: General,
_general: General,

Check failure on line 67 in lading/src/generator/container.rs

View workflow job for this annotation

GitHub Actions / Rust Actions (Check/Fmt/Clippy) (ubuntu-latest)

this argument is passed by value, but not consumed in the function body

Check failure on line 67 in lading/src/generator/container.rs

View workflow job for this annotation

GitHub Actions / Rust Actions (Check/Fmt/Clippy) (macos-latest)

this argument is passed by value, but not consumed in the function body
config: &Config,
shutdown: lading_signal::Watcher,
) -> Result<Self, Error> {
Expand Down

0 comments on commit 3ba8f27

Please sign in to comment.