feat: disable crowdsec #12
@@ -89,12 +89,10 @@ jobs:
|
||||
with:
|
||||
namespace: kube-system
|
||||
secret-name: admin-basic-auth-credentials
|
||||
secret-type: generic
|
||||
data: |
|
||||
{
|
||||
"username": "bmV0YWRtaW4=",
|
||||
"password": "${{ secrets.ADMIN_BASIC_AUTH_PASSWORD }}"
|
||||
}
|
||||
secret-type: "kubernetes.io/basic-auth"
|
||||
string-data: |
|
||||
username: netadmin
|
||||
password: "${{ secrets.ADMIN_BASIC_AUTH_PASSWORD }}"
|
||||
- name: Set crowdsec bouncer api key
|
||||
uses: azure/k8s-create-secret@6e0ba8047235646753f2a3a3b359b4d0006ff218 # v5
|
||||
with:
|
||||
|
||||
8
traefik/middleware-adminbasicauth.yaml
Normal file
8
traefik/middleware-adminbasicauth.yaml
Normal file
@@ -0,0 +1,8 @@
|
||||
apiVersion: traefik.containo.us/v1alpha1
|
||||
kind: Middleware
|
||||
metadata:
|
||||
name: adminbasicauth
|
||||
namespace: kube-system
|
||||
spec:
|
||||
basicAuth:
|
||||
secret: admin-basic-auth-credentials
|
||||
13
traefik/middleware-crowdsec-bouncher.yaml
Normal file
13
traefik/middleware-crowdsec-bouncher.yaml
Normal file
@@ -0,0 +1,13 @@
|
||||
apiVersion: traefik.containo.us/v1alpha1
|
||||
kind: Middleware
|
||||
metadata:
|
||||
name: crowdsec-bouncer
|
||||
namespace: kube-system
|
||||
spec:
|
||||
plugin:
|
||||
crowdsec-bouncer-traefik-plugin:
|
||||
Enabled: true
|
||||
CrowdsecMode: live
|
||||
CrowdsecLapiUrl: "http://crowdsec-service.kube-system.svc.cluster.local:8080"
|
||||
CrowdsecLapiKey: "${CROWDSEC_BOUNCER_API_KEY}"
|
||||
UpdateIntervalSeconds: 10
|
||||
11
traefik/middleware-local-ip-filter.yaml
Normal file
11
traefik/middleware-local-ip-filter.yaml
Normal file
@@ -0,0 +1,11 @@
|
||||
apiVersion: traefik.containo.us/v1alpha1
|
||||
kind: Middleware
|
||||
metadata:
|
||||
name: localipfilter
|
||||
namespace: kube-system
|
||||
spec:
|
||||
ipWhiteList:
|
||||
sourceRange:
|
||||
- 192.168.0.0/24
|
||||
- 172.16.0.0/16
|
||||
- 10.0.0.0/8
|
||||
@@ -69,32 +69,12 @@ spec:
|
||||
size: 1Gi
|
||||
storageClass: longhorn
|
||||
path: /data
|
||||
extraObjects:
|
||||
- apiVersion: traefik.containo.us/v1alpha1
|
||||
kind: Middleware
|
||||
metadata:
|
||||
name: localipfilter
|
||||
namespace: kube-system
|
||||
spec:
|
||||
ipWhiteList:
|
||||
sourceRange:
|
||||
- 192.168.0.0/24
|
||||
- 172.16.0.0/16
|
||||
- 10.0.0.0/8
|
||||
- apiVersion: traefik.containo.us/v1alpha1
|
||||
kind: Middleware
|
||||
metadata:
|
||||
name: adminbasicauth
|
||||
namespace: kube-system
|
||||
spec:
|
||||
basicAuth:
|
||||
secret: adminbasicauthsecret
|
||||
experimental:
|
||||
plugins:
|
||||
crowdsec-bouncer-traefik-plugin:
|
||||
moduleName: github.com/maxlerebourg/crowdsec-bouncer-traefik-plugin
|
||||
version: v1.4.6
|
||||
additionalArguments:
|
||||
- "--providers.kubernetescrd"
|
||||
- "--entrypoints.web.http.middlewares=crowdsec-bouncer@kubernetescrd"
|
||||
- "--entrypoints.websecure.http.middlewares=internal-crowdsec-bouncer@kubernetescrd"
|
||||
#experimental:
|
||||
# plugins:
|
||||
# crowdsec-bouncer-traefik-plugin:
|
||||
# moduleName: github.com/maxlerebourg/crowdsec-bouncer-traefik-plugin
|
||||
# version: v1.4.6
|
||||
#additionalArguments:
|
||||
# - "--providers.kubernetescrd"
|
||||
# - "--entrypoints.web.http.middlewares=crowdsec-bouncer@kubernetescrd"
|
||||
# - "--entrypoints.websecure.http.middlewares=kube-system-crowdsec-bouncer@kubernetescrd"
|
||||
|
||||
Reference in New Issue
Block a user