Corex / Kubernetes /deployment.yml
yadavkapil23's picture
Corex Codes
b09d5e9
raw
history blame contribute delete
830 Bytes
apiVersion: apps/v1
kind: Deployment
metadata:
name: rag-app
namespace: rag
spec:
replicas: 1
selector:
matchLabels:
app: rag-app
template:
metadata:
labels:
app: rag-app
spec:
containers:
- name: rag-container
image: yadavkapil23/rag-app:latest
ports:
- containerPort: 8000
# --- NEW CODE: INJECT HUGGINGFACE TOKEN FROM A SECRET ---
env:
- name: HUGGINGFACE_API_TOKEN
valueFrom:
secretKeyRef:
# You must create a secret named 'huggingface-secret' beforehand
name: huggingface-secret
# Assuming the key inside the secret is also named HUGGINGFACE_API_TOKEN
key: HUGGINGFACE_API_TOKEN
# --------------------------------------------------------