pub enum AnonymousPolicy {
Allow,
Refuse {
browse_host: Option<String>,
},
}Expand description
The --anonymous knob (the browse replica). Anonymous reads of
public repositories are either served here (Allow, the default and every
pre-2026-09 server) or refused with a line that names the browse replica
they are served by (Refuse). Strangers cost CPU and bandwidth on the box
that also takes the paying writes; the browse replica is where that cost
belongs, and the primary sends them there rather than quietly 404-ing.
Variants§
Allow
Serve anonymous reads of public repositories on this box.
Refuse
Refuse every anonymous request; browse_host, when named, goes into
the refusal so git clone prints where to clone from instead.
Trait Implementations§
Source§impl Clone for AnonymousPolicy
impl Clone for AnonymousPolicy
Source§impl Debug for AnonymousPolicy
impl Debug for AnonymousPolicy
Source§impl Default for AnonymousPolicy
impl Default for AnonymousPolicy
impl Eq for AnonymousPolicy
Source§impl PartialEq for AnonymousPolicy
impl PartialEq for AnonymousPolicy
impl StructuralPartialEq for AnonymousPolicy
Auto Trait Implementations§
impl Freeze for AnonymousPolicy
impl RefUnwindSafe for AnonymousPolicy
impl Send for AnonymousPolicy
impl Sync for AnonymousPolicy
impl Unpin for AnonymousPolicy
impl UnsafeUnpin for AnonymousPolicy
impl UnwindSafe for AnonymousPolicy
Blanket Implementations§
impl<T> Allocation for T
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.