Compare commits
	
		
			No commits in common. "f0709ed83b098785013980d3335f33c3410dc3b6" and "e8cd50c85783501edbbfa1d789c5e6c0649ab079" have entirely different histories.
		
	
	
		
			f0709ed83b
			...
			e8cd50c857
		
	
		
							
								
								
									
										2
									
								
								.gitignore
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										2
									
								
								.gitignore
									
									
									
									
										vendored
									
									
								
							@ -1,5 +1,3 @@
 | 
				
			|||||||
.env
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
traefik/acme.json
 | 
					traefik/acme.json
 | 
				
			||||||
traefik/certs/
 | 
					traefik/certs/
 | 
				
			||||||
traefik/traefik.log
 | 
					traefik/traefik.log
 | 
				
			||||||
 | 
				
			|||||||
@ -1,38 +1,42 @@
 | 
				
			|||||||
# log:
 | 
					host: 0.0.0.0
 | 
				
			||||||
#   level: debug
 | 
					port: 9091
 | 
				
			||||||
 | 
					logs_level: trace
 | 
				
			||||||
theme: auto
 | 
					jwt_secret: {{ env.Getenv "PRIVATE_DOMAIN" }}-jwt-secret
 | 
				
			||||||
authentication_backend:
 | 
					authentication_backend:
 | 
				
			||||||
  file:
 | 
					  file:
 | 
				
			||||||
    path: /config/users_database.yml
 | 
					    path: /opt/authelia/users_database.yml
 | 
				
			||||||
 | 
					
 | 
				
			||||||
session:
 | 
					session:
 | 
				
			||||||
  # domain: SET BY ENV VARIABLE AUTHELIA_SESSION_DOMAIN
 | 
					  name: authelia_session
 | 
				
			||||||
  # secret: SET BY ENV VARIABLE AUTHELIA_SESSION_SECRET
 | 
					  secret: {{ env.Getenv "PRIVATE_DOMAIN" }}-token-secret
 | 
				
			||||||
 | 
					  domain: {{ env.Getenv "PRIVATE_DOMAIN" }}
 | 
				
			||||||
 | 
					  expiration: 604800
 | 
				
			||||||
 | 
					  inactivity: 172800
 | 
				
			||||||
 | 
					
 | 
				
			||||||
storage:
 | 
					storage:
 | 
				
			||||||
  local:
 | 
					  local:
 | 
				
			||||||
    path: /config/db.sqlite3
 | 
					    path: /opt/authelia/db.sqlite3
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					totp:
 | 
				
			||||||
 | 
					  issuer: {{ env.Getenv "PRIVATE_DOMAIN" }}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
access_control:
 | 
					access_control:
 | 
				
			||||||
  default_policy: two_factor
 | 
					  default_policy: one_factor
 | 
				
			||||||
  networks:
 | 
					 | 
				
			||||||
    - name: internal
 | 
					 | 
				
			||||||
      networks:
 | 
					 | 
				
			||||||
        - 10.0.0.0/8
 | 
					 | 
				
			||||||
        - 172.16.0.0/12
 | 
					 | 
				
			||||||
        - 192.168.0.0/18
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
  rules:
 | 
					  rules:
 | 
				
			||||||
    # Allow free access from local network
 | 
					    # Allow free access from local network
 | 
				
			||||||
    - domain:
 | 
					    - domain: "*"
 | 
				
			||||||
      - "*.se"
 | 
					 | 
				
			||||||
      - "*.com"
 | 
					 | 
				
			||||||
      networks:
 | 
					      networks:
 | 
				
			||||||
        - internal
 | 
					        - 192.168.1.0/23
 | 
				
			||||||
      policy: bypass
 | 
					      policy: bypass
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					regulation:
 | 
				
			||||||
 | 
					  max_retries: 5
 | 
				
			||||||
 | 
					  find_time: 120
 | 
				
			||||||
 | 
					  ban_time: 180
 | 
				
			||||||
 | 
					
 | 
				
			||||||
notifier:
 | 
					notifier:
 | 
				
			||||||
  filesystem:
 | 
					  filesystem:
 | 
				
			||||||
    filename: /config/notification.txt
 | 
					    filename: /opt/authelia/notification.txt
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
				
			|||||||
@ -25,10 +25,8 @@ services:
 | 
				
			|||||||
      - EMAIL
 | 
					      - EMAIL
 | 
				
			||||||
      - PRIVATE_DOMAIN
 | 
					      - PRIVATE_DOMAIN
 | 
				
			||||||
      - PUBLIC_DOMAIN
 | 
					      - PUBLIC_DOMAIN
 | 
				
			||||||
      - TRAEFIK_CERTIFICATERESOLVERS_LE_ACME_EMAIL
 | 
					 | 
				
			||||||
    networks:
 | 
					    networks:
 | 
				
			||||||
      web:
 | 
					      web:
 | 
				
			||||||
        ipv4_address: 172.18.1.2
 | 
					 | 
				
			||||||
    command:
 | 
					    command:
 | 
				
			||||||
      - "--configFile=/data/traefik.yaml"
 | 
					      - "--configFile=/data/traefik.yaml"
 | 
				
			||||||
    ports:
 | 
					    ports:
 | 
				
			||||||
@ -50,20 +48,29 @@ services:
 | 
				
			|||||||
      traefik.http.routers.traefik.tls.certResolver: le
 | 
					      traefik.http.routers.traefik.tls.certResolver: le
 | 
				
			||||||
      autoheal: "true"
 | 
					      autoheal: "true"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  authelia-config:
 | 
				
			||||||
 | 
					    # Preprocess authelia configuration through gomplate
 | 
				
			||||||
 | 
					    image: hairyhenderson/gomplate
 | 
				
			||||||
 | 
					    environment:
 | 
				
			||||||
 | 
					      - PRIVATE_DOMAIN
 | 
				
			||||||
 | 
					      - PUBLIC_DOMAIN
 | 
				
			||||||
 | 
					    volumes:
 | 
				
			||||||
 | 
					      - ./authelia/configuration.yml:/data/input:ro
 | 
				
			||||||
 | 
					      - authelia-config:/data/output
 | 
				
			||||||
 | 
					    command: '--file=/data/input --out=/data/output/configuration.yml'
 | 
				
			||||||
  authelia:
 | 
					  authelia:
 | 
				
			||||||
    container_name: authelia
 | 
					    container_name: authelia
 | 
				
			||||||
    image: authelia/authelia
 | 
					    image: authelia/authelia
 | 
				
			||||||
    restart: always
 | 
					    restart: always
 | 
				
			||||||
 | 
					    depends_on:
 | 
				
			||||||
 | 
					      # config preprocessor should run first
 | 
				
			||||||
 | 
					      - authelia-config
 | 
				
			||||||
    volumes:
 | 
					    volumes:
 | 
				
			||||||
      - ./authelia:/config
 | 
					      - ./authelia:/opt/authelia
 | 
				
			||||||
 | 
					      - authelia-config:/etc/authelia/
 | 
				
			||||||
    environment:
 | 
					    environment:
 | 
				
			||||||
      # - ENVIRONMENT=dev
 | 
					      - ENVIRONMENT=dev
 | 
				
			||||||
      - NODE_TLS_REJECT_UNAUTHORIZED=1
 | 
					      - NODE_TLS_REJECT_UNAUTHORIZED=1
 | 
				
			||||||
      - AUTHELIA_JWT_SECRET
 | 
					 | 
				
			||||||
      - AUTHELIA_SESSION_SECRET
 | 
					 | 
				
			||||||
      - AUTHELIA_SESSION_DOMAIN
 | 
					 | 
				
			||||||
      - AUTHELIA_TOTP_ISSUER
 | 
					 | 
				
			||||||
      - TZ=Europe/Stockholm
 | 
					 | 
				
			||||||
    networks:
 | 
					    networks:
 | 
				
			||||||
      web:
 | 
					      web:
 | 
				
			||||||
    healthcheck:
 | 
					    healthcheck:
 | 
				
			||||||
@ -88,41 +95,26 @@ services:
 | 
				
			|||||||
      web:
 | 
					      web:
 | 
				
			||||||
    labels:
 | 
					    labels:
 | 
				
			||||||
      traefik.enable: true
 | 
					      traefik.enable: true
 | 
				
			||||||
      traefik.http.routers.homer.rule: Host(`${PRIVATE_DOMAIN}`) || Host(`www.${PRIVATE_DOMAIN}`)
 | 
					      traefik.http.routers.homer.rule: Host(`${PRIVATE_DOMAIN}`)
 | 
				
			||||||
      traefik.http.routers.homer.tls.certResolver: le
 | 
					      traefik.http.routers.homer.tls.certResolver: le
 | 
				
			||||||
 | 
					      traefik.http.routers.homer.entrypoints: websecure
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  dozzle:
 | 
					# whoami-https:
 | 
				
			||||||
    image: amir20/dozzle
 | 
					#   image: containous/whoami
 | 
				
			||||||
    restart: always
 | 
					#   networks:
 | 
				
			||||||
    volumes:
 | 
					#     web:
 | 
				
			||||||
      - /var/run/docker.sock:/var/run/docker.sock
 | 
					#   labels:
 | 
				
			||||||
    networks:
 | 
					#     traefik.enable: true
 | 
				
			||||||
      web:
 | 
					#     traefik.http.routers.wait-https.rule: Host(`wai-https.${PRIVATE_DOMAIN}`)
 | 
				
			||||||
    labels:
 | 
					#     traefik.http.routers.wait-https.tls.certResolver: le
 | 
				
			||||||
      traefik.enable: true
 | 
					 | 
				
			||||||
      traefik.http.routers.dozzle.rule: Host(`logs.${PRIVATE_DOMAIN}`)
 | 
					 | 
				
			||||||
      traefik.http.routers.dozzle.tls.certResolver: le
 | 
					 | 
				
			||||||
      traefik.http.routers.dozzle.middlewares: auth@file
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# whoami-auth:
 | 
				
			||||||
# labels:
 | 
					#   image: containous/whoami
 | 
				
			||||||
#   The following three labels are always needed. Make sure to replace <SERVICE> with a unique name
 | 
					#   networks:
 | 
				
			||||||
#   traefik.enable: true
 | 
					#     web:
 | 
				
			||||||
#   traefik.http.routers.<SERVICE>.tls.certResolver: le
 | 
					#     macvlan:
 | 
				
			||||||
#   traefik.http.routers.<SERVICE>.rule: Host(`<SERVICE>.${PRIVATE_DOMAIN}`)
 | 
					#   labels:
 | 
				
			||||||
 | 
					#     traefik.enable: true
 | 
				
			||||||
#   Alternatives:
 | 
					#     traefik.http.routers.wai-auth.rule: Host(`wai-auth.${PRIVATE_DOMAIN}`)
 | 
				
			||||||
#   traefik.http.routers.<SERVICE>.rule: Host(`<SERVICE>.${PUBLIC_DOMAIN}`)
 | 
					#     traefik.http.routers.wai-auth.tls.certResolver: le
 | 
				
			||||||
#   traefik.http.routers.<SERVICE>.rule: Host(`<SERVICE>.${PRIVATE_DOMAIN}`) || HOST(`<SERVICE>.${PUBLIC_DOMAIN}`)
 | 
					#     traefik.http.routers.wai-auth.middlewares: auth@file
 | 
				
			||||||
 | 
					 | 
				
			||||||
#   Require authentication:
 | 
					 | 
				
			||||||
#   traefik.http.routers.<SERVICE>.middlewares: auth@file
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
#   If more than one port is exposed by the container:
 | 
					 | 
				
			||||||
#   traefik.http.services.<SERVICE>.loadbalancer.server.port: <PORT>
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
#   If container uses more than one network:
 | 
					 | 
				
			||||||
#   traefik.docker.network: web
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
#   Restart automatically if healthchech fails:
 | 
					 | 
				
			||||||
#   autoheal: "true"
 | 
					 | 
				
			||||||
 | 
				
			|||||||
@ -9,12 +9,7 @@ http:
 | 
				
			|||||||
    proxmox:
 | 
					    proxmox:
 | 
				
			||||||
      loadBalancer:
 | 
					      loadBalancer:
 | 
				
			||||||
        servers:
 | 
					        servers:
 | 
				
			||||||
          - url: https://192.168.0.10:8006
 | 
					          - url: http://192.168.0.10:8006
 | 
				
			||||||
    prusa:
 | 
					 | 
				
			||||||
      loadBalancer:
 | 
					 | 
				
			||||||
        servers:
 | 
					 | 
				
			||||||
          - url: http://192.168.0.14
 | 
					 | 
				
			||||||
          
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
  routers:
 | 
					  routers:
 | 
				
			||||||
    pfsense:
 | 
					    pfsense:
 | 
				
			||||||
@ -31,11 +26,4 @@ http:
 | 
				
			|||||||
        - auth
 | 
					        - auth
 | 
				
			||||||
      tls:
 | 
					      tls:
 | 
				
			||||||
        certResolver: le
 | 
					        certResolver: le
 | 
				
			||||||
    prusa:
 | 
					 | 
				
			||||||
      service: prusa
 | 
					 | 
				
			||||||
      rule: Host(`prusa.{{env "PRIVATE_DOMAIN"}}`)
 | 
					 | 
				
			||||||
      middlewares:
 | 
					 | 
				
			||||||
        - auth
 | 
					 | 
				
			||||||
      tls:
 | 
					 | 
				
			||||||
        certResolver: le
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
				
			|||||||
@ -13,8 +13,7 @@ http:
 | 
				
			|||||||
      # Catch all requests to the http entrypoint and redirect them to https
 | 
					      # Catch all requests to the http entrypoint and redirect them to https
 | 
				
			||||||
      service: http-catchall
 | 
					      service: http-catchall
 | 
				
			||||||
      rule: hostregexp(`{host:.+}`)
 | 
					      rule: hostregexp(`{host:.+}`)
 | 
				
			||||||
      entryPoints:
 | 
					      entrypoint: web
 | 
				
			||||||
        - web
 | 
					 | 
				
			||||||
      middlewares:
 | 
					      middlewares:
 | 
				
			||||||
        - redir
 | 
					        - redir
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
				
			|||||||
@ -12,7 +12,7 @@ providers:
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
log:
 | 
					log:
 | 
				
			||||||
  filePath: /data/traefik.log
 | 
					  filePath: /data/traefik.log
 | 
				
			||||||
  level: INFO
 | 
					  level: DEBUG
 | 
				
			||||||
 | 
					
 | 
				
			||||||
entryPoints:
 | 
					entryPoints:
 | 
				
			||||||
  web:
 | 
					  web:
 | 
				
			||||||
@ -23,8 +23,7 @@ entryPoints:
 | 
				
			|||||||
certificatesResolvers:
 | 
					certificatesResolvers:
 | 
				
			||||||
  le:
 | 
					  le:
 | 
				
			||||||
    acme:
 | 
					    acme:
 | 
				
			||||||
      # caServer: https://acme-staging-v02.api.letsencrypt.org/directory
 | 
					      email: '{{ env "EMAIL" }}'
 | 
				
			||||||
      # email: SET BY ENV VARIABLE TRAEFIK_CERTIFICATERESOLVERS_LE_ACME_EMAIL
 | 
					 | 
				
			||||||
      storage: /data/acme.json
 | 
					      storage: /data/acme.json
 | 
				
			||||||
      httpChallenge:
 | 
					      httpChallenge:
 | 
				
			||||||
        entrypoint: web
 | 
					        entrypoint: web
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user