-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
local-dev: traefik: use file configuration
This means the docker socket doesn't need to be mounted into the traefik container, at the cost/advantage of putting the config in separate files instead of container labels. Signed-off-by: Hank Donnay <hdonnay@redhat.com>
- Loading branch information
Showing
8 changed files
with
146 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
--- | ||
http: | ||
entrypoint: | ||
clair: | ||
address: ':6060' | ||
routers: | ||
indexer: | ||
entryPoints: [clair] | ||
rule: 'PathPrefix(`/indexer`)' | ||
service: indexer | ||
matcher: | ||
entryPoints: [clair] | ||
rule: 'PathPrefix(`/matcher`)' | ||
service: matcher | ||
notifier: | ||
entryPoints: [clair] | ||
rule: 'PathPrefix(`/notifier`)' | ||
service: notifier | ||
services: | ||
indexer: | ||
loadBalancer: | ||
servers: | ||
- url: "http://clair-indexer:6060/" | ||
healthCheck: | ||
path: /healthz | ||
port: 8089 | ||
matcher: | ||
loadBalancer: | ||
servers: | ||
- url: "http://clair-matcher:6060/" | ||
healthCheck: | ||
path: /healthz | ||
port: 8089 | ||
notifier: | ||
loadBalancer: | ||
servers: | ||
- url: "http://clair-notifier:6060/" | ||
healthCheck: | ||
path: /healthz | ||
port: 8089 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
--- | ||
http: | ||
routers: | ||
api: | ||
entryPoints: [traefik] | ||
rule: 'PathPrefix(`/api`) || PathPrefix(`/dashboard`)' | ||
service: 'api@internal' | ||
dashboard-redirect: | ||
entryPoints: [traefik] | ||
rule: 'Path(`/`)' | ||
middlewares: [dashboard-redirect] | ||
service: 'api@internal' | ||
middlewares: | ||
dashboard-redirect: | ||
redirectRegex: | ||
regex: '.*' | ||
replacement: '${1}/dashboard/' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
--- | ||
http: | ||
routers: | ||
grafana: | ||
entryPoints: [traefik] | ||
rule: 'PathPrefix(`/grafana`)' | ||
service: grafana | ||
services: | ||
grafana: | ||
loadBalancer: | ||
servers: | ||
- url: "http://clair-grafana:3000/" | ||
healthCheck: | ||
path: /grafana/api/health |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
--- | ||
http: | ||
routers: | ||
jaeger: | ||
entryPoints: [traefik] | ||
rule: 'PathPrefix(`/jaeger`)' | ||
service: jaeger | ||
services: | ||
jaeger: | ||
loadBalancer: | ||
servers: | ||
- url: "http://clair-jaeger:16686/" | ||
healthCheck: | ||
path: / |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
--- | ||
http: | ||
routers: | ||
pgadmin: | ||
entryPoints: [traefik] | ||
rule: 'PathPrefix(`/pgadmin`)' | ||
service: pgadmin | ||
services: | ||
pgadmin: | ||
loadBalancer: | ||
servers: | ||
- url: "http://clair-pgadmin/" | ||
healthCheck: | ||
path: /pgadmin |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
--- | ||
tcp: | ||
routers: | ||
postgresql: | ||
entryPoints: [postgresql] | ||
service: postgresql | ||
# Traefik docs say this hack is needed if not using TLS. | ||
rule: 'HostSNI(`*`)' | ||
services: | ||
postgresql: | ||
loadBalancer: | ||
servers: | ||
- address: 'clair-database:5432' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
--- | ||
http: | ||
routers: | ||
prom: | ||
entryPoints: [traefik] | ||
rule: 'PathPrefix(`/prom`)' | ||
service: prom | ||
services: | ||
prom: | ||
loadBalancer: | ||
servers: | ||
- url: "http://clair-prometheus:9090/" | ||
healthCheck: | ||
path: /prom/-/healthy |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
--- | ||
global: | ||
sendAnonymousUsage: false | ||
api: | ||
insecure: false | ||
dashboard: true | ||
entryPoints: | ||
traefik: | ||
address: ':8080' | ||
clair: | ||
address: ':6060' | ||
postgresql: | ||
address: ':5432' | ||
providers: | ||
file: | ||
directory: /etc/traefik/config | ||
metrics: | ||
prometheus: | ||
addServicesLabels: true | ||
accessLog: {} |