apiVersion: apps/v1
kind: Deployment
metadata:
  name: frontend
  namespace: juwan
  labels:
    app: frontend
spec:
  replicas: 1
  selector:
    matchLabels:
      app: frontend
  template:
    metadata:
      labels:
        app: frontend
    spec:
      imagePullSecrets:
        - name: registry-creds
      containers:
      - name: frontend
        image: registry.juwan.xhttp.zip/juwan/frontend:latest
        ports:
        - name: http
          containerPort: 3000
        resources:
          requests:
            cpu: 10m
            memory: 32Mi
          limits:
            memory: 512Mi

---
apiVersion: v1
kind: Service
metadata:
  name: frontend-svc
  namespace: juwan
spec:
  ports:
    - name: http
      port: 3000
      targetPort: 3000
  selector:
    app: frontend
