pub struct Redirect {
pub name: String,
pub zone_id: Uuid,
pub code: u16,
pub location: String,
pub tls: String,
pub created_at: i64,
pub updated_at: i64,
pub certificate: Option<RedirectCertificate>,
}Expand description
An HTTP(S) redirect that Relay answers for a host name inside one of the caller’s zones.
Core keeps the DNS records that point the name at the platform (a CNAME below the
apex, A/AAAA at the apex, RecordManager::Redirect)
and removes them with the redirect.
Fields§
§name: StringHost name the redirect answers for: lowercase, without trailing dot. Unique across the platform; this is how a redirect is addressed.
zone_id: UuidZone the host name belongs to.
code: u16HTTP status code, one of REDIRECT_CODES today.
location: StringTarget http:// or https:// URL.
tls: StringAuto, Manual or None (kept as a string for forward compatibility); see
RedirectTls and Redirect::tls_mode.
created_at: i64Unix seconds.
updated_at: i64Unix seconds.
certificate: Option<RedirectCertificate>State of the automatic certificate; only for tls = Auto.
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Redirect
impl<'de> Deserialize<'de> for Redirect
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for Redirect
impl RefUnwindSafe for Redirect
impl Send for Redirect
impl Sync for Redirect
impl Unpin for Redirect
impl UnsafeUnpin for Redirect
impl UnwindSafe for Redirect
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more