diff --git a/CHANGELOG.md b/CHANGELOG.md index f162e2a3..211d5fc5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,7 +1,15 @@ # Changelog +### unftp-auth-gcs v0.2.6 + +- Compiled against libunftp v0.20.0 +- Fix listing when root path is set (#509) +- Upgraded dependencies + ### libunftp 0.20.0 +_tag: libunftp-0.10.0_ + - Compile against Rust 1.78.0 - Added support for Capsicum on FreeBSD (#481) - Fixed proxy protocol issue #494 when removing stale data channel diff --git a/crates/unftp-sbe-gcs/Cargo.toml b/crates/unftp-sbe-gcs/Cargo.toml index de10c9b2..10098252 100644 --- a/crates/unftp-sbe-gcs/Cargo.toml +++ b/crates/unftp-sbe-gcs/Cargo.toml @@ -1,7 +1,7 @@ [package] name = "unftp-sbe-gcs" description = "A storage back-end for libunftp, storing files in Google Cloud Storage (GCS)" -version = "0.2.5" +version = "0.2.6" authors = [ "Agoston Horvath ", "Dávid Kosztka ", diff --git a/crates/unftp-sbe-gcs/README.md b/crates/unftp-sbe-gcs/README.md index d214b0da..2544fd10 100644 --- a/crates/unftp-sbe-gcs/README.md +++ b/crates/unftp-sbe-gcs/README.md @@ -15,45 +15,45 @@ Add the needed dependencies to Cargo.toml: ```toml [dependencies] - libunftp = "0.20.0" - unftp-sbe-gcs = "0.2.5" - tokio = { version = "1", features = ["full"] } +libunftp = "0.20.0" +unftp-sbe-gcs = "0.2.6" +tokio = { version = "1", features = ["full"] } ``` And add to src/main.rs: ```rust use libunftp::Server; - use unftp_sbe_gcs::{ServerExt, options::AuthMethod}; - use std::path::PathBuf; +use unftp_sbe_gcs::{ServerExt, options::AuthMethod}; +use std::path::PathBuf; - #[tokio::main] - pub async fn main() { - let server = Server::with_gcs("my-bucket", PathBuf::from("/unftp"), AuthMethod::WorkloadIdentity(None)) - .greeting("Welcome to my FTP server") - .passive_ports(50000..65535); +#[tokio::main] +pub async fn main() { + let server = Server::with_gcs("my-bucket", PathBuf::from("/unftp"), AuthMethod::WorkloadIdentity(None)) + .greeting("Welcome to my FTP server") + .passive_ports(50000..65535); - server.listen("127.0.0.1:2121").await; - } + server.listen("127.0.0.1:2121").await; +} ``` The above example uses the `ServerExt` extension trait. You can also call one of the other constructors of `Server` e.g. ```rust use libunftp::Server; - use unftp_sbe_gcs::{CloudStorage, options::AuthMethod}; - use std::path::PathBuf; - - #[tokio::main] - pub async fn main() { - let server = libunftp::Server::new( - Box::new(move || CloudStorage::with_bucket_root("my-bucket", PathBuf::from("/ftp-root"), AuthMethod::WorkloadIdentity(None))) - ) - .greeting("Welcome to my FTP server") - .passive_ports(50000..65535); - - server.listen("127.0.0.1:2121").await; - } +use unftp_sbe_gcs::{CloudStorage, options::AuthMethod}; +use std::path::PathBuf; + +#[tokio::main] +pub async fn main() { + let server = libunftp::Server::new( + Box::new(move || CloudStorage::with_bucket_root("my-bucket", PathBuf::from("/ftp-root"), AuthMethod::WorkloadIdentity(None))) + ) + .greeting("Welcome to my FTP server") + .passive_ports(50000..65535); + + server.listen("127.0.0.1:2121").await; +} ``` For more usage information see the `examples` directory and