2023-03-20 14:38:08 +00:00
|
|
|
apiVersion: traefik.io/v1alpha1
|
2020-01-07 10:26:05 +00:00
|
|
|
kind: TraefikService
|
|
|
|
metadata:
|
|
|
|
name: wrr2
|
|
|
|
namespace: default
|
|
|
|
|
|
|
|
spec:
|
|
|
|
weighted:
|
|
|
|
services:
|
|
|
|
- name: s1
|
|
|
|
weight: 1
|
|
|
|
port: 80
|
|
|
|
# Optional, as it is the default value
|
|
|
|
kind: Service
|
|
|
|
- name: s3
|
|
|
|
weight: 1
|
|
|
|
port: 80
|
|
|
|
|
|
|
|
---
|
2023-03-20 14:38:08 +00:00
|
|
|
apiVersion: traefik.io/v1alpha1
|
2020-01-07 10:26:05 +00:00
|
|
|
kind: TraefikService
|
|
|
|
metadata:
|
|
|
|
name: wrr1
|
|
|
|
namespace: default
|
|
|
|
|
|
|
|
spec:
|
|
|
|
weighted:
|
|
|
|
services:
|
|
|
|
- name: wrr2
|
|
|
|
kind: TraefikService
|
|
|
|
weight: 1
|
|
|
|
- name: s3
|
|
|
|
weight: 1
|
|
|
|
port: 80
|
|
|
|
|
|
|
|
---
|
2023-03-20 14:38:08 +00:00
|
|
|
apiVersion: traefik.io/v1alpha1
|
2020-01-07 10:26:05 +00:00
|
|
|
kind: TraefikService
|
|
|
|
metadata:
|
|
|
|
name: mirror1
|
|
|
|
namespace: default
|
|
|
|
|
|
|
|
spec:
|
|
|
|
mirroring:
|
|
|
|
name: s1
|
|
|
|
port: 80
|
|
|
|
mirrors:
|
|
|
|
- name: s3
|
|
|
|
percent: 20
|
|
|
|
port: 80
|
|
|
|
- name: mirror2
|
|
|
|
kind: TraefikService
|
|
|
|
percent: 20
|
|
|
|
|
|
|
|
---
|
2023-03-20 14:38:08 +00:00
|
|
|
apiVersion: traefik.io/v1alpha1
|
2020-01-07 10:26:05 +00:00
|
|
|
kind: TraefikService
|
|
|
|
metadata:
|
|
|
|
name: mirror2
|
|
|
|
namespace: default
|
|
|
|
|
|
|
|
spec:
|
|
|
|
mirroring:
|
|
|
|
name: wrr2
|
|
|
|
kind: TraefikService
|
2024-09-02 14:36:06 +00:00
|
|
|
mirrorBody: true
|
2021-03-03 14:32:04 +00:00
|
|
|
# Optional
|
|
|
|
maxBodySize: 2000000000
|
2020-01-07 10:26:05 +00:00
|
|
|
mirrors:
|
|
|
|
- name: s2
|
|
|
|
# Optional, as it is the default value
|
|
|
|
kind: Service
|
|
|
|
percent: 20
|
|
|
|
port: 80
|
|
|
|
|
|
|
|
---
|
2023-03-20 14:38:08 +00:00
|
|
|
apiVersion: traefik.io/v1alpha1
|
2020-01-07 10:26:05 +00:00
|
|
|
kind: IngressRoute
|
|
|
|
metadata:
|
|
|
|
name: ingressroute
|
2021-03-03 14:32:04 +00:00
|
|
|
|
2020-01-07 10:26:05 +00:00
|
|
|
spec:
|
|
|
|
entryPoints:
|
|
|
|
- web
|
2020-01-23 15:36:08 +00:00
|
|
|
- websecure
|
2020-01-07 10:26:05 +00:00
|
|
|
routes:
|
2020-03-13 21:50:05 +00:00
|
|
|
- match: Host(`example.net`) && PathPrefix(`/bar`)
|
2020-01-07 10:26:05 +00:00
|
|
|
kind: Rule
|
|
|
|
priority: 12
|
|
|
|
# defining several services is possible and allowed, but for now the servers of
|
|
|
|
# all the services (for a given route) get merged altogether under the same
|
|
|
|
# load-balancing strategy.
|
|
|
|
services:
|
|
|
|
- name: s1
|
|
|
|
port: 80
|
|
|
|
# strategy defines the load balancing strategy between the servers. It defaults
|
|
|
|
# to Round Robin, and for now only Round Robin is supported anyway.
|
|
|
|
strategy: RoundRobin
|
|
|
|
- name: s2
|
|
|
|
port: 433
|
2021-02-01 12:58:03 +00:00
|
|
|
serversTransport: mytransport
|
2020-01-07 10:26:05 +00:00
|
|
|
- match: PathPrefix(`/misc`)
|
2021-03-03 14:32:04 +00:00
|
|
|
kind: Rule
|
2020-01-07 10:26:05 +00:00
|
|
|
services:
|
|
|
|
- name: s3
|
|
|
|
port: 80
|
|
|
|
middlewares:
|
|
|
|
- name: stripprefix
|
|
|
|
- name: addprefix
|
|
|
|
- match: PathPrefix(`/misc`)
|
2021-03-03 14:32:04 +00:00
|
|
|
kind: Rule
|
2020-01-07 10:26:05 +00:00
|
|
|
services:
|
|
|
|
- name: s3
|
|
|
|
# Optional, as it is the default value
|
|
|
|
kind: Service
|
|
|
|
port: 8443
|
|
|
|
# scheme allow to override the scheme for the service. (ex: https or h2c)
|
|
|
|
scheme: https
|
|
|
|
- match: PathPrefix(`/lb`)
|
2021-03-03 14:32:04 +00:00
|
|
|
kind: Rule
|
2020-01-07 10:26:05 +00:00
|
|
|
services:
|
|
|
|
- name: wrr1
|
|
|
|
kind: TraefikService
|
|
|
|
- match: PathPrefix(`/mirrored`)
|
2021-03-03 14:32:04 +00:00
|
|
|
kind: Rule
|
2020-01-07 10:26:05 +00:00
|
|
|
services:
|
|
|
|
- name: mirror1
|
|
|
|
kind: TraefikService
|
|
|
|
# use an empty tls object for TLS with Let's Encrypt
|
|
|
|
tls:
|
|
|
|
secretName: supersecret
|
|
|
|
options:
|
2020-04-28 15:18:04 +00:00
|
|
|
name: my-tls-option
|
2020-01-07 10:26:05 +00:00
|
|
|
namespace: default
|
|
|
|
|
|
|
|
---
|
2023-03-20 14:38:08 +00:00
|
|
|
apiVersion: traefik.io/v1alpha1
|
2020-01-07 10:26:05 +00:00
|
|
|
kind: IngressRouteTCP
|
|
|
|
metadata:
|
|
|
|
name: ingressroutetcp.crd
|
|
|
|
namespace: default
|
|
|
|
|
|
|
|
spec:
|
|
|
|
entryPoints:
|
|
|
|
- footcp
|
|
|
|
routes:
|
2020-03-13 21:50:05 +00:00
|
|
|
- match: HostSNI(`example.com`)
|
2020-01-07 10:26:05 +00:00
|
|
|
services:
|
|
|
|
- name: whoamitcp
|
|
|
|
port: 8080
|
2022-12-09 08:58:05 +00:00
|
|
|
serversTransport: mytransporttcp
|
2021-06-11 13:30:05 +00:00
|
|
|
middlewares:
|
2022-10-26 15:16:05 +00:00
|
|
|
- name: ipallowlist
|
2020-01-07 10:26:05 +00:00
|
|
|
tls:
|
|
|
|
secretName: foosecret
|
|
|
|
passthrough: false
|
|
|
|
options:
|
2020-04-28 15:18:04 +00:00
|
|
|
name: my-tls-option
|
2020-01-07 10:26:05 +00:00
|
|
|
namespace: default
|
2020-02-12 17:06:04 +00:00
|
|
|
|
2020-02-26 11:28:05 +00:00
|
|
|
---
|
2023-03-20 14:38:08 +00:00
|
|
|
apiVersion: traefik.io/v1alpha1
|
2020-02-26 11:28:05 +00:00
|
|
|
kind: IngressRouteUDP
|
|
|
|
metadata:
|
|
|
|
name: ingressrouteudp.crd
|
|
|
|
namespace: default
|
|
|
|
|
|
|
|
spec:
|
|
|
|
entryPoints:
|
|
|
|
- footcp
|
|
|
|
routes:
|
|
|
|
- services:
|
|
|
|
- name: whoamiudp
|
|
|
|
port: 8080
|
|
|
|
|
2020-02-12 17:06:04 +00:00
|
|
|
---
|
2023-03-20 14:38:08 +00:00
|
|
|
apiVersion: traefik.io/v1alpha1
|
2020-02-12 17:06:04 +00:00
|
|
|
kind: TLSOption
|
|
|
|
metadata:
|
|
|
|
name: tlsoption
|
|
|
|
namespace: default
|
|
|
|
|
|
|
|
spec:
|
|
|
|
minVersion: foobar
|
|
|
|
maxVersion: foobar
|
|
|
|
cipherSuites:
|
|
|
|
- foobar
|
|
|
|
- foobar
|
|
|
|
curvePreferences:
|
|
|
|
- foobar
|
|
|
|
- foobar
|
|
|
|
clientAuth:
|
2021-03-03 14:32:04 +00:00
|
|
|
secretNames:
|
2020-02-12 17:06:04 +00:00
|
|
|
- foobar
|
|
|
|
- foobar
|
2021-03-03 14:32:04 +00:00
|
|
|
clientAuthType: RequireAndVerifyClientCert
|
2020-02-12 17:06:04 +00:00
|
|
|
sniStrict: true
|
2021-08-20 16:20:06 +00:00
|
|
|
alpnProtocols:
|
|
|
|
- foobar
|
|
|
|
- foobar
|
2020-09-11 13:40:03 +00:00
|
|
|
|
|
|
|
---
|
2023-03-20 14:38:08 +00:00
|
|
|
apiVersion: traefik.io/v1alpha1
|
2020-09-11 13:40:03 +00:00
|
|
|
kind: ServersTransport
|
|
|
|
metadata:
|
|
|
|
name: mytransport
|
|
|
|
namespace: default
|
|
|
|
|
|
|
|
spec:
|
|
|
|
serverName: foobar
|
|
|
|
insecureSkipVerify: true
|
|
|
|
rootCAsSecrets:
|
|
|
|
- foobar
|
|
|
|
- foobar
|
|
|
|
certificatesSecrets:
|
|
|
|
- foobar
|
|
|
|
- foobar
|
2022-12-09 08:58:05 +00:00
|
|
|
peerCertURI: foobar
|
2020-09-11 13:40:03 +00:00
|
|
|
maxIdleConnsPerHost: 1
|
|
|
|
forwardingTimeouts:
|
|
|
|
dialTimeout: 42s
|
|
|
|
responseHeaderTimeout: 42s
|
|
|
|
idleConnTimeout: 42s
|
2021-03-29 12:32:03 +00:00
|
|
|
disableHTTP2: true
|
2022-12-09 08:58:05 +00:00
|
|
|
|
|
|
|
---
|
2023-03-21 11:00:46 +00:00
|
|
|
apiVersion: traefik.io/v1alpha1
|
2022-12-09 08:58:05 +00:00
|
|
|
kind: ServersTransportTCP
|
|
|
|
metadata:
|
|
|
|
name: mytransporttcp
|
|
|
|
namespace: default
|
|
|
|
|
|
|
|
spec:
|
|
|
|
serverName: foobar
|
|
|
|
insecureSkipVerify: true
|
|
|
|
rootCAsSecrets:
|
|
|
|
- foobar
|
|
|
|
- foobar
|
|
|
|
certificatesSecrets:
|
|
|
|
- foobar
|
|
|
|
- foobar
|
|
|
|
peerCertURI: foobar
|
|
|
|
dialTimeout: 42s
|
|
|
|
dialKeepAlive: 42s
|