Skip to content

Instantly share code, notes, and snippets.

@lluked
Created April 25, 2022 20:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lluked/771a1f7f9bbd8ef2581e8828f3b25f9e to your computer and use it in GitHub Desktop.
Save lluked/771a1f7f9bbd8ef2581e8828f3b25f9e to your computer and use it in GitHub Desktop.
Splunk-Traefik-without-Root-Endpoint
version: "2.2"
services:
splunk:
image: splunk/splunk
restart: always
cap_add: ['IPC_LOCK']
ulimits:
memlock:
soft: -1
hard: -1
nofile:
soft: 65536
hard: 65536
environment:
SPLUNK_START_ARGS: "--accept-license"
SPLUNK_PASSWORD: "changeme"
networks:
- splunk
ports:
- "8000:8000"
traefik:
image: "traefik:2.7"
restart: always
volumes:
- ./splunk_dynamic.yml:/etc/traefik/conf/splunk_dynamic.yml:ro
- ./traefik.yml:/etc/traefik/traefik.yml:ro
networks:
- splunk
ports:
- "80:80"
- "443:443"
networks:
splunk:
http:
routers:
splunk:
entryPoints:
- websecure
rule: PathPrefix(`/`)
service: splunk-service
tls: {}
services:
splunk-service:
loadBalancer:
servers:
- url: "http://splunk:8000"
entryPoints:
web:
address: ":80"
http:
redirections:
entrypoint:
to: websecure
scheme: https
websecure:
address: ":443"
providers:
file:
directory: "/etc/traefik/conf"
log:
filePath: "/var/log/traefik.json"
format: json
accessLog:
filePath: "/var/log/access.log"
filters:
statusCodes:
- "401"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment