mirror of
https://git.mirrors.martin98.com/https://github.com/mendableai/firecrawl
synced 2025-08-12 23:49:07 +08:00
Update Kubernetes YAMLs and add worker service
Refactored container configurations in worker, api, and playwright-service YAMLs to streamline syntax and add missing fields. Added a service definition for the worker component and included a new environment variable in the configmap for rate-limiting. These changes enhance configuration clarity and ensure proper resource definitions.
This commit is contained in:
parent
f26bda2477
commit
d68f349109
@ -15,37 +15,35 @@ spec:
|
|||||||
imagePullSecrets:
|
imagePullSecrets:
|
||||||
- name: docker-registry-secret
|
- name: docker-registry-secret
|
||||||
containers:
|
containers:
|
||||||
- name: api
|
- name: api
|
||||||
image: ghcr.io/winkk-dev/firecrawl:latest
|
image: ghcr.io/winkk-dev/firecrawl:latest
|
||||||
imagePullPolicy: Always
|
imagePullPolicy: Always
|
||||||
args: [ "pnpm", "run", "start:production" ]
|
args: [ "pnpm", "run", "start:production" ]
|
||||||
ports:
|
ports:
|
||||||
- containerPort: 3002
|
- containerPort: 3002
|
||||||
envFrom:
|
envFrom:
|
||||||
- configMapRef:
|
- configMapRef:
|
||||||
name: firecrawl-config
|
name: firecrawl-config
|
||||||
#- secretRef:
|
#- secretRef:
|
||||||
# name: firecrawl-secret
|
# name: firecrawl-secret
|
||||||
- livenessProbe:
|
livenessProbe:
|
||||||
httpGet:
|
httpGet:
|
||||||
path: /v0/health/liveness
|
path: /v0/health/liveness
|
||||||
port: 3002
|
port: 3002
|
||||||
initialDelaySeconds: 30
|
initialDelaySeconds: 30
|
||||||
periodSeconds: 30
|
periodSeconds: 30
|
||||||
timeoutSeconds: 5
|
timeoutSeconds: 5
|
||||||
successThreshold: 1
|
successThreshold: 1
|
||||||
failureThreshold: 3
|
failureThreshold: 3
|
||||||
name: api-container
|
readinessProbe:
|
||||||
- readinessProbe:
|
httpGet:
|
||||||
httpGet:
|
path: /v0/health/readiness
|
||||||
path: /v0/health/readiness
|
port: 3002
|
||||||
port: 3002
|
initialDelaySeconds: 30
|
||||||
initialDelaySeconds: 30
|
periodSeconds: 30
|
||||||
periodSeconds: 30
|
timeoutSeconds: 5
|
||||||
timeoutSeconds: 5
|
successThreshold: 1
|
||||||
successThreshold: 1
|
failureThreshold: 3
|
||||||
failureThreshold: 3
|
|
||||||
name: api-container
|
|
||||||
---
|
---
|
||||||
apiVersion: v1
|
apiVersion: v1
|
||||||
kind: Service
|
kind: Service
|
||||||
|
@ -7,6 +7,7 @@ data:
|
|||||||
PORT: "3002"
|
PORT: "3002"
|
||||||
HOST: "0.0.0.0"
|
HOST: "0.0.0.0"
|
||||||
REDIS_URL: "redis://redis:6379"
|
REDIS_URL: "redis://redis:6379"
|
||||||
|
REDIS_RATE_LIMIT_URL: "redis://redis:6379"
|
||||||
PLAYWRIGHT_MICROSERVICE_URL: "http://playwright-service:3000/html"
|
PLAYWRIGHT_MICROSERVICE_URL: "http://playwright-service:3000/html"
|
||||||
USE_DB_AUTHENTICATION: "false"
|
USE_DB_AUTHENTICATION: "false"
|
||||||
HDX_NODE_BETA_MODE: "1"
|
HDX_NODE_BETA_MODE: "1"
|
||||||
|
@ -22,34 +22,32 @@ spec:
|
|||||||
imagePullSecrets:
|
imagePullSecrets:
|
||||||
- name: docker-registry-secret
|
- name: docker-registry-secret
|
||||||
containers:
|
containers:
|
||||||
- name: playwright-service
|
- name: playwright-service
|
||||||
image: ghcr.io/winkk-dev/firecrawl-playwright:latest
|
image: ghcr.io/winkk-dev/firecrawl-playwright:latest
|
||||||
imagePullPolicy: Always
|
imagePullPolicy: Always
|
||||||
ports:
|
ports:
|
||||||
- containerPort: 3000
|
- containerPort: 3000
|
||||||
envFrom:
|
envFrom:
|
||||||
- configMapRef:
|
- configMapRef:
|
||||||
name: playwright-service-config
|
name: playwright-service-config
|
||||||
- livenessProbe:
|
livenessProbe:
|
||||||
httpGet:
|
httpGet:
|
||||||
path: /health/liveness
|
path: /health/liveness
|
||||||
port: 3000
|
port: 3000
|
||||||
initialDelaySeconds: 30
|
initialDelaySeconds: 30
|
||||||
periodSeconds: 30
|
periodSeconds: 30
|
||||||
timeoutSeconds: 5
|
timeoutSeconds: 5
|
||||||
successThreshold: 1
|
successThreshold: 1
|
||||||
failureThreshold: 3
|
failureThreshold: 3
|
||||||
name: playwright-service-container
|
readinessProbe:
|
||||||
- readinessProbe:
|
httpGet:
|
||||||
httpGet:
|
path: /health/readiness
|
||||||
path: /health/readiness
|
port: 3000
|
||||||
port: 3000
|
initialDelaySeconds: 30
|
||||||
initialDelaySeconds: 30
|
periodSeconds: 30
|
||||||
periodSeconds: 30
|
timeoutSeconds: 5
|
||||||
timeoutSeconds: 5
|
successThreshold: 1
|
||||||
successThreshold: 1
|
failureThreshold: 3
|
||||||
failureThreshold: 3
|
|
||||||
name: playwright-service-container
|
|
||||||
---
|
---
|
||||||
apiVersion: v1
|
apiVersion: v1
|
||||||
kind: Service
|
kind: Service
|
||||||
|
@ -15,31 +15,42 @@ spec:
|
|||||||
imagePullSecrets:
|
imagePullSecrets:
|
||||||
- name: docker-registry-secret
|
- name: docker-registry-secret
|
||||||
containers:
|
containers:
|
||||||
- name: worker
|
- name: worker
|
||||||
image: ghcr.io/winkk-dev/firecrawl:latest
|
image: ghcr.io/winkk-dev/firecrawl:latest
|
||||||
imagePullPolicy: Always
|
imagePullPolicy: Always
|
||||||
envFrom:
|
args: [ "pnpm", "run", "workers" ]
|
||||||
- configMapRef:
|
envFrom:
|
||||||
name: firecrawl-config
|
- configMapRef:
|
||||||
#- secretRef:
|
name: firecrawl-config
|
||||||
# name: firecrawl-secret
|
#- secretRef:
|
||||||
- livenessProbe:
|
# name: firecrawl-secret
|
||||||
httpGet:
|
livenessProbe:
|
||||||
path: /v0/health/liveness
|
httpGet:
|
||||||
port: 3002
|
path: /v0/health/liveness
|
||||||
initialDelaySeconds: 30
|
port: 3003
|
||||||
periodSeconds: 30
|
initialDelaySeconds: 30
|
||||||
timeoutSeconds: 5
|
periodSeconds: 30
|
||||||
successThreshold: 1
|
timeoutSeconds: 5
|
||||||
failureThreshold: 3
|
successThreshold: 1
|
||||||
name: worker-container
|
failureThreshold: 3
|
||||||
- readinessProbe:
|
readinessProbe:
|
||||||
httpGet:
|
httpGet:
|
||||||
path: /v0/health/readiness
|
path: /v0/health/readiness
|
||||||
port: 3002
|
port: 3003
|
||||||
initialDelaySeconds: 30
|
initialDelaySeconds: 30
|
||||||
periodSeconds: 30
|
periodSeconds: 30
|
||||||
timeoutSeconds: 5
|
timeoutSeconds: 5
|
||||||
successThreshold: 1
|
successThreshold: 1
|
||||||
failureThreshold: 3
|
failureThreshold: 3
|
||||||
name: worker-container
|
---
|
||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: worker
|
||||||
|
spec:
|
||||||
|
selector:
|
||||||
|
app: worker
|
||||||
|
ports:
|
||||||
|
- protocol: TCP
|
||||||
|
port: 3003
|
||||||
|
targetPort: 3003
|
||||||
|
Loading…
x
Reference in New Issue
Block a user