mirror of
https://github.com/openziti/zrok.git
synced 2025-04-12 13:28:23 +02:00
global limits for reserved shares and unique names (#632)
This commit is contained in:
parent
fc403a6c22
commit
7d18bea46c
@ -5,11 +5,13 @@ import "time"
|
|||||||
const Unlimited = -1
|
const Unlimited = -1
|
||||||
|
|
||||||
type Config struct {
|
type Config struct {
|
||||||
Environments int
|
Environments int
|
||||||
Shares int
|
Shares int
|
||||||
Bandwidth *BandwidthConfig
|
ReservedShares int
|
||||||
Cycle time.Duration
|
UniqueNames int
|
||||||
Enforcing bool
|
Bandwidth *BandwidthConfig
|
||||||
|
Cycle time.Duration
|
||||||
|
Enforcing bool
|
||||||
}
|
}
|
||||||
|
|
||||||
type BandwidthConfig struct {
|
type BandwidthConfig struct {
|
||||||
@ -48,8 +50,10 @@ func DefaultBandwidthPerPeriod() *BandwidthPerPeriod {
|
|||||||
|
|
||||||
func DefaultConfig() *Config {
|
func DefaultConfig() *Config {
|
||||||
return &Config{
|
return &Config{
|
||||||
Environments: Unlimited,
|
Environments: Unlimited,
|
||||||
Shares: Unlimited,
|
Shares: Unlimited,
|
||||||
|
ReservedShares: Unlimited,
|
||||||
|
UniqueNames: Unlimited,
|
||||||
Bandwidth: &BandwidthConfig{
|
Bandwidth: &BandwidthConfig{
|
||||||
PerAccount: DefaultBandwidthPerPeriod(),
|
PerAccount: DefaultBandwidthPerPeriod(),
|
||||||
PerEnvironment: DefaultBandwidthPerPeriod(),
|
PerEnvironment: DefaultBandwidthPerPeriod(),
|
||||||
|
Loading…
Reference in New Issue
Block a user