forked from roger/k3s-cluster
searxng
This commit is contained in:
24
argocd/apps/searxng.yaml
Normal file
24
argocd/apps/searxng.yaml
Normal file
@@ -0,0 +1,24 @@
|
|||||||
|
apiVersion: argoproj.io/v1alpha1
|
||||||
|
kind: Application
|
||||||
|
metadata:
|
||||||
|
name: searxng
|
||||||
|
namespace: argocd
|
||||||
|
annotations:
|
||||||
|
argocd.argoproj.io/sync-wave: "0"
|
||||||
|
spec:
|
||||||
|
project: k3s-cluster
|
||||||
|
source:
|
||||||
|
repoURL: https://git.rogi.casa/roger/k3s-cluster.git
|
||||||
|
targetRevision: main
|
||||||
|
path: searxng
|
||||||
|
directory:
|
||||||
|
recurse: true
|
||||||
|
destination:
|
||||||
|
server: https://kubernetes.default.svc
|
||||||
|
namespace: searxng
|
||||||
|
syncPolicy:
|
||||||
|
automated:
|
||||||
|
prune: true
|
||||||
|
selfHeal: true
|
||||||
|
syncOptions:
|
||||||
|
- CreateNamespace=false
|
||||||
25
searxng/ingress.yaml
Normal file
25
searxng/ingress.yaml
Normal file
@@ -0,0 +1,25 @@
|
|||||||
|
---
|
||||||
|
apiVersion: networking.k8s.io/v1
|
||||||
|
kind: Ingress
|
||||||
|
metadata:
|
||||||
|
name: searxng
|
||||||
|
namespace: searxng
|
||||||
|
annotations:
|
||||||
|
cert-manager.io/cluster-issuer: letsencrypt-prod
|
||||||
|
spec:
|
||||||
|
ingressClassName: traefik
|
||||||
|
tls:
|
||||||
|
- hosts:
|
||||||
|
- search.rogi.casa
|
||||||
|
secretName: searxng-tls
|
||||||
|
rules:
|
||||||
|
- host: search.rogi.casa
|
||||||
|
http:
|
||||||
|
paths:
|
||||||
|
- path: /
|
||||||
|
pathType: Prefix
|
||||||
|
backend:
|
||||||
|
service:
|
||||||
|
name: searxng
|
||||||
|
port:
|
||||||
|
number: 8080
|
||||||
182
searxng/searxng.yaml
Normal file
182
searxng/searxng.yaml
Normal file
@@ -0,0 +1,182 @@
|
|||||||
|
---
|
||||||
|
apiVersion: v1
|
||||||
|
kind: Namespace
|
||||||
|
metadata:
|
||||||
|
name: searxng
|
||||||
|
labels:
|
||||||
|
app.kubernetes.io/name: searxng
|
||||||
|
app.kubernetes.io/instance: searxng
|
||||||
|
---
|
||||||
|
apiVersion: v1
|
||||||
|
kind: ConfigMap
|
||||||
|
metadata:
|
||||||
|
name: searxng-config
|
||||||
|
namespace: searxng
|
||||||
|
labels:
|
||||||
|
app.kubernetes.io/name: searxng
|
||||||
|
app.kubernetes.io/instance: searxng
|
||||||
|
data:
|
||||||
|
settings.yml: |
|
||||||
|
use_default_settings: true
|
||||||
|
general:
|
||||||
|
instance_name: "SearXNG"
|
||||||
|
debug: false
|
||||||
|
search:
|
||||||
|
safe_search: 0
|
||||||
|
autocomplete: ""
|
||||||
|
default_lang: "en"
|
||||||
|
formats:
|
||||||
|
- html
|
||||||
|
server:
|
||||||
|
# secret_key is provided via the SEARXNG_SECRET env var from the searxng-secret Secret
|
||||||
|
limiter: false
|
||||||
|
image_proxy: true
|
||||||
|
bind_address: "0.0.0.0"
|
||||||
|
port: 8080
|
||||||
|
ui:
|
||||||
|
static_use_hash: true
|
||||||
|
redis:
|
||||||
|
url: redis://searxng-redis:6379/0
|
||||||
|
---
|
||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
name: searxng-redis
|
||||||
|
namespace: searxng
|
||||||
|
labels:
|
||||||
|
app.kubernetes.io/name: searxng
|
||||||
|
app.kubernetes.io/instance: searxng
|
||||||
|
app.kubernetes.io/component: redis
|
||||||
|
spec:
|
||||||
|
replicas: 1
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
app.kubernetes.io/name: searxng
|
||||||
|
app.kubernetes.io/instance: searxng
|
||||||
|
app.kubernetes.io/component: redis
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
app.kubernetes.io/name: searxng
|
||||||
|
app.kubernetes.io/instance: searxng
|
||||||
|
app.kubernetes.io/component: redis
|
||||||
|
spec:
|
||||||
|
containers:
|
||||||
|
- name: redis
|
||||||
|
image: redis:7-alpine
|
||||||
|
ports:
|
||||||
|
- containerPort: 6379
|
||||||
|
name: redis
|
||||||
|
resources:
|
||||||
|
limits:
|
||||||
|
cpu: 100m
|
||||||
|
memory: 64Mi
|
||||||
|
requests:
|
||||||
|
cpu: 25m
|
||||||
|
memory: 32Mi
|
||||||
|
---
|
||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: searxng-redis
|
||||||
|
namespace: searxng
|
||||||
|
labels:
|
||||||
|
app.kubernetes.io/name: searxng
|
||||||
|
app.kubernetes.io/instance: searxng
|
||||||
|
app.kubernetes.io/component: redis
|
||||||
|
spec:
|
||||||
|
selector:
|
||||||
|
app.kubernetes.io/name: searxng
|
||||||
|
app.kubernetes.io/instance: searxng
|
||||||
|
app.kubernetes.io/component: redis
|
||||||
|
ports:
|
||||||
|
- name: redis
|
||||||
|
protocol: TCP
|
||||||
|
port: 6379
|
||||||
|
targetPort: 6379
|
||||||
|
type: ClusterIP
|
||||||
|
---
|
||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
name: searxng
|
||||||
|
namespace: searxng
|
||||||
|
labels:
|
||||||
|
app.kubernetes.io/name: searxng
|
||||||
|
app.kubernetes.io/instance: searxng
|
||||||
|
spec:
|
||||||
|
replicas: 1
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
app.kubernetes.io/name: searxng
|
||||||
|
app.kubernetes.io/instance: searxng
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
app.kubernetes.io/name: searxng
|
||||||
|
app.kubernetes.io/instance: searxng
|
||||||
|
spec:
|
||||||
|
containers:
|
||||||
|
- name: searxng
|
||||||
|
image: searxng/searxng:latest
|
||||||
|
env:
|
||||||
|
- name: SEARXNG_SECRET
|
||||||
|
valueFrom:
|
||||||
|
secretKeyRef:
|
||||||
|
name: searxng-secret
|
||||||
|
key: SEARXNG_SECRET
|
||||||
|
ports:
|
||||||
|
- containerPort: 8080
|
||||||
|
name: http
|
||||||
|
volumeMounts:
|
||||||
|
- mountPath: /etc/searxng/settings.yml
|
||||||
|
name: searxng-config
|
||||||
|
subPath: settings.yml
|
||||||
|
resources:
|
||||||
|
limits:
|
||||||
|
cpu: 500m
|
||||||
|
memory: 512Mi
|
||||||
|
requests:
|
||||||
|
cpu: 100m
|
||||||
|
memory: 128Mi
|
||||||
|
livenessProbe:
|
||||||
|
httpGet:
|
||||||
|
path: /healthz
|
||||||
|
port: 8080
|
||||||
|
scheme: HTTP
|
||||||
|
initialDelaySeconds: 30
|
||||||
|
timeoutSeconds: 5
|
||||||
|
periodSeconds: 10
|
||||||
|
successThreshold: 1
|
||||||
|
failureThreshold: 6
|
||||||
|
readinessProbe:
|
||||||
|
httpGet:
|
||||||
|
path: /healthz
|
||||||
|
port: 8080
|
||||||
|
scheme: HTTP
|
||||||
|
initialDelaySeconds: 5
|
||||||
|
timeoutSeconds: 5
|
||||||
|
periodSeconds: 10
|
||||||
|
volumes:
|
||||||
|
- name: searxng-config
|
||||||
|
configMap:
|
||||||
|
name: searxng-config
|
||||||
|
---
|
||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: searxng
|
||||||
|
namespace: searxng
|
||||||
|
labels:
|
||||||
|
app.kubernetes.io/name: searxng
|
||||||
|
app.kubernetes.io/instance: searxng
|
||||||
|
spec:
|
||||||
|
selector:
|
||||||
|
app.kubernetes.io/name: searxng
|
||||||
|
app.kubernetes.io/instance: searxng
|
||||||
|
ports:
|
||||||
|
- name: http
|
||||||
|
protocol: TCP
|
||||||
|
port: 8080
|
||||||
|
targetPort: 8080
|
||||||
|
type: ClusterIP
|
||||||
Reference in New Issue
Block a user