mirror of
https://github.com/rustfs/rustfs.git
synced 2026-08-10 15:16:56 +00:00
d3cff7d033
Signed-off-by: yxrxy <1532529704@qq.com> Co-authored-by: houseme <housemecn@gmail.com> Co-authored-by: 马登山 <Cxymds@qq.com> Co-authored-by: heihutu <30542132+heihutu@users.noreply.github.com> Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> Co-authored-by: 安正超 <anzhengchao@gmail.com>
60 lines
2.5 KiB
Rust
60 lines
2.5 KiB
Rust
// Copyright 2024 RustFS Team
|
|
//
|
|
// Licensed under the Apache License, Version 2.0 (the "License");
|
|
// you may not use this file except in compliance with the License.
|
|
// You may obtain a copy of the License at
|
|
//
|
|
// http://www.apache.org/licenses/LICENSE-2.0
|
|
//
|
|
// Unless required by applicable law or agreed to in writing, software
|
|
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
// See the License for the specific language governing permissions and
|
|
// limitations under the License.
|
|
|
|
//! Protocol server configuration constants
|
|
|
|
/// Default FTP server bind address (non-encrypted)
|
|
pub const DEFAULT_FTP_ADDRESS: &str = "0.0.0.0:8021";
|
|
|
|
/// Default FTPS server bind address (FTP over TLS)
|
|
pub const DEFAULT_FTPS_ADDRESS: &str = "0.0.0.0:8022";
|
|
|
|
/// Default FTP passive ports range (optional)
|
|
pub const DEFAULT_FTP_PASSIVE_PORTS: Option<&str> = None;
|
|
|
|
/// Default FTPS passive ports range (optional)
|
|
pub const DEFAULT_FTPS_PASSIVE_PORTS: Option<&str> = None;
|
|
|
|
/// Default FTP external IP (auto-detected)
|
|
pub const DEFAULT_FTP_EXTERNAL_IP: Option<&str> = None;
|
|
|
|
/// Default FTPS external IP (auto-detected)
|
|
pub const DEFAULT_FTPS_EXTERNAL_IP: Option<&str> = None;
|
|
|
|
/// Environment variable names
|
|
pub const ENV_FTP_ENABLE: &str = "RUSTFS_FTP_ENABLE";
|
|
pub const ENV_FTP_ADDRESS: &str = "RUSTFS_FTP_ADDRESS";
|
|
pub const ENV_FTP_PASSIVE_PORTS: &str = "RUSTFS_FTP_PASSIVE_PORTS";
|
|
pub const ENV_FTP_EXTERNAL_IP: &str = "RUSTFS_FTP_EXTERNAL_IP";
|
|
|
|
pub const ENV_FTPS_ENABLE: &str = "RUSTFS_FTPS_ENABLE";
|
|
pub const ENV_FTPS_ADDRESS: &str = "RUSTFS_FTPS_ADDRESS";
|
|
pub const ENV_FTPS_TLS_ENABLED: &str = "RUSTFS_FTPS_TLS_ENABLED";
|
|
pub const ENV_FTPS_CERTS_DIR: &str = "RUSTFS_FTPS_CERTS_DIR";
|
|
pub const ENV_FTPS_CA_FILE: &str = "RUSTFS_FTPS_CA_FILE";
|
|
pub const ENV_FTPS_PASSIVE_PORTS: &str = "RUSTFS_FTPS_PASSIVE_PORTS";
|
|
pub const ENV_FTPS_EXTERNAL_IP: &str = "RUSTFS_FTPS_EXTERNAL_IP";
|
|
|
|
/// Default WebDAV server bind address
|
|
pub const DEFAULT_WEBDAV_ADDRESS: &str = "0.0.0.0:8080";
|
|
|
|
/// WebDAV environment variable names
|
|
pub const ENV_WEBDAV_ENABLE: &str = "RUSTFS_WEBDAV_ENABLE";
|
|
pub const ENV_WEBDAV_ADDRESS: &str = "RUSTFS_WEBDAV_ADDRESS";
|
|
pub const ENV_WEBDAV_TLS_ENABLED: &str = "RUSTFS_WEBDAV_TLS_ENABLED";
|
|
pub const ENV_WEBDAV_CERTS_DIR: &str = "RUSTFS_WEBDAV_CERTS_DIR";
|
|
pub const ENV_WEBDAV_CA_FILE: &str = "RUSTFS_WEBDAV_CA_FILE";
|
|
pub const ENV_WEBDAV_MAX_BODY_SIZE: &str = "RUSTFS_WEBDAV_MAX_BODY_SIZE";
|
|
pub const ENV_WEBDAV_REQUEST_TIMEOUT: &str = "RUSTFS_WEBDAV_REQUEST_TIMEOUT";
|