mirror of
https://github.com/aykhans/my-self-host-services.git
synced 2026-05-29 15:35:59 +00:00
Compare commits
1 Commits
main
..
14e6115618
| Author | SHA1 | Date | |
|---|---|---|---|
| 14e6115618 |
+2
-4
@@ -53,12 +53,10 @@
|
|||||||
{$GITEA_DOMAIN} {
|
{$GITEA_DOMAIN} {
|
||||||
import access-log
|
import access-log
|
||||||
request_body {
|
request_body {
|
||||||
max_size 2048MB
|
max_size 512MB
|
||||||
}
|
}
|
||||||
@not_registry not path /v2/*
|
|
||||||
route {
|
route {
|
||||||
crowdsec
|
import security
|
||||||
appsec @not_registry
|
|
||||||
reverse_proxy http://gitea:3000 {
|
reverse_proxy http://gitea:3000 {
|
||||||
header_up Host {http.request.host}
|
header_up Host {http.request.host}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4,7 +4,6 @@
|
|||||||
# and in caddy/.env (CADDY) and the host firewall bouncer config (FW).
|
# and in caddy/.env (CADDY) and the host firewall bouncer config (FW).
|
||||||
CROWDSEC_BOUNCER_KEY_CADDY=
|
CROWDSEC_BOUNCER_KEY_CADDY=
|
||||||
CROWDSEC_BOUNCER_KEY_FW=
|
CROWDSEC_BOUNCER_KEY_FW=
|
||||||
CROWDSEC_BOUNCER_KEY_EXPORTER=
|
|
||||||
|
|
||||||
############# Console enrollment #############
|
############# Console enrollment #############
|
||||||
# Enroll key from https://app.crowdsec.net (free).
|
# Enroll key from https://app.crowdsec.net (free).
|
||||||
|
|||||||
@@ -26,7 +26,6 @@ services:
|
|||||||
Dominic-Wagner/vaultwarden
|
Dominic-Wagner/vaultwarden
|
||||||
BOUNCER_KEY_caddy: "${CROWDSEC_BOUNCER_KEY_CADDY}"
|
BOUNCER_KEY_caddy: "${CROWDSEC_BOUNCER_KEY_CADDY}"
|
||||||
BOUNCER_KEY_firewall: "${CROWDSEC_BOUNCER_KEY_FW}"
|
BOUNCER_KEY_firewall: "${CROWDSEC_BOUNCER_KEY_FW}"
|
||||||
BOUNCER_KEY_exporter: "${CROWDSEC_BOUNCER_KEY_EXPORTER}"
|
|
||||||
ENROLL_KEY: "${CROWDSEC_ENROLL_KEY:-}"
|
ENROLL_KEY: "${CROWDSEC_ENROLL_KEY:-}"
|
||||||
ENROLL_INSTANCE_NAME: "${CROWDSEC_ENROLL_INSTANCE_NAME:-aykhans-prod}"
|
ENROLL_INSTANCE_NAME: "${CROWDSEC_ENROLL_INSTANCE_NAME:-aykhans-prod}"
|
||||||
ports:
|
ports:
|
||||||
@@ -62,7 +61,7 @@ services:
|
|||||||
- caddy
|
- caddy
|
||||||
environment:
|
environment:
|
||||||
CROWDSEC_LAPI_URL: "http://crowdsec:8080"
|
CROWDSEC_LAPI_URL: "http://crowdsec:8080"
|
||||||
CROWDSEC_API_KEY: "${CROWDSEC_BOUNCER_KEY_EXPORTER}"
|
CROWDSEC_API_KEY: "${CROWDSEC_BOUNCER_KEY_CADDY}"
|
||||||
POLL_INTERVAL_SECS: "30"
|
POLL_INTERVAL_SECS: "30"
|
||||||
LISTEN_PORT: "9100"
|
LISTEN_PORT: "9100"
|
||||||
GEOIP_CITY_DB: "/geoip/GeoLite2-City.mmdb"
|
GEOIP_CITY_DB: "/geoip/GeoLite2-City.mmdb"
|
||||||
|
|||||||
@@ -1,18 +1,18 @@
|
|||||||
name: default_ip_remediation
|
name: default_ip_remediation
|
||||||
filters:
|
filters:
|
||||||
- Alert.Remediation == true && Alert.GetScope() == "Ip"
|
- Alert.Remediation == true && Alert.GetScope() == "Ip"
|
||||||
duration_expr: Sprintf('%dh', min(730, (GetDecisionsCount(Alert.GetValue())+1)*4))
|
|
||||||
decisions:
|
decisions:
|
||||||
- type: ban
|
- type: ban
|
||||||
duration: 4h
|
duration: 4h
|
||||||
|
duration_expr: Sprintf('%dh', min(168, (GetDecisionsCount(Alert.GetValue())+1)*4))
|
||||||
on_success: break
|
on_success: break
|
||||||
|
|
||||||
---
|
---
|
||||||
name: default_range_remediation
|
name: default_range_remediation
|
||||||
filters:
|
filters:
|
||||||
- Alert.Remediation == true && Alert.GetScope() == "Range"
|
- Alert.Remediation == true && Alert.GetScope() == "Range"
|
||||||
duration_expr: Sprintf('%dh', min(730, (GetDecisionsCount(Alert.GetValue())+1)*4))
|
|
||||||
decisions:
|
decisions:
|
||||||
- type: ban
|
- type: ban
|
||||||
duration: 4h
|
duration: 4h
|
||||||
|
duration_expr: Sprintf('%dh', min(168, (GetDecisionsCount(Alert.GetValue())+1)*4))
|
||||||
on_success: break
|
on_success: break
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ networks:
|
|||||||
|
|
||||||
services:
|
services:
|
||||||
memos:
|
memos:
|
||||||
image: neosmemo/memos:0.29
|
image: neosmemo/memos:0.27
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
container_name: memos
|
container_name: memos
|
||||||
labels:
|
labels:
|
||||||
|
|||||||
@@ -10,7 +10,7 @@ services:
|
|||||||
- "--label-enable"
|
- "--label-enable"
|
||||||
- "--cleanup"
|
- "--cleanup"
|
||||||
- "--interval"
|
- "--interval"
|
||||||
- "28800" # 8 hours
|
- "600" # 10 minutes
|
||||||
logging:
|
logging:
|
||||||
driver: "json-file"
|
driver: "json-file"
|
||||||
options:
|
options:
|
||||||
|
|||||||
Reference in New Issue
Block a user