mirror of
https://github.com/phfroidmont/self-hosting.git
synced 2025-12-25 05:36:59 +01:00
Manage manifests with k8s module
This commit is contained in:
parent
6ffa138ab1
commit
5955b3ac42
6 changed files with 64 additions and 78 deletions
50
roles/k8s-manifests/tasks/searx.yml
Normal file
50
roles/k8s-manifests/tasks/searx.yml
Normal file
|
|
@ -0,0 +1,50 @@
|
|||
- name: Searx deployment
|
||||
k8s:
|
||||
namespace: default
|
||||
state: present
|
||||
definition:
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: searx
|
||||
spec:
|
||||
replicas: 2
|
||||
selector:
|
||||
matchLabels:
|
||||
app: searx
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: searx
|
||||
spec:
|
||||
containers:
|
||||
- name: searx
|
||||
image: wonderfall/searx:latest
|
||||
imagePullPolicy: IfNotPresent
|
||||
ports:
|
||||
- containerPort: 8888
|
||||
livenessProbe:
|
||||
httpGet:
|
||||
path: /
|
||||
port: 8888
|
||||
readinessProbe:
|
||||
httpGet:
|
||||
path: /
|
||||
port: 8888
|
||||
|
||||
- name: Searx service
|
||||
k8s:
|
||||
namespace: default
|
||||
state: present
|
||||
definition:
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: searx
|
||||
spec:
|
||||
type: ClusterIP
|
||||
ports:
|
||||
- port: 80
|
||||
targetPort: 8888
|
||||
selector:
|
||||
app: searx
|
||||
Loading…
Add table
Add a link
Reference in a new issue