<p>I tried setting up <strong>gitea</strong> in my local kubernetes cluster. At first it was working I can access the gitea home page. But when I tried to reboot my raspberry pi. I got the below error on my <code>Service</code></p>
<p><a href="https://i.stack.imgur.com/UKgqr.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/UKgqr.png" alt="enter image description here" /></a></p>
<p>My <code>pod</code> is ok.
<a href="https://i.stack.imgur.com/CO9Ys.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/CO9Ys.png" alt="enter image description here" /></a></p>
<p>I'm wondering why I only got this error every time i reboot my device.</p>
<p>here are my configuraiton</p>
<pre><code>kind: Service
apiVersion: v1
metadata:
  name: gitea-service
spec:
  type: NodePort
  selector:
    app: gitea
  ports:
  - name: gitea-http
    port: 3000
    targetPort: 3000
    nodePort: 30000
  - name: gitea-ssh
    port: 22
    targetPort: 22
    nodePort: 30002
</code></pre>
<pre><code>apiVersion: apps/v1
kind: StatefulSet
metadata:
  name: gitea-deployment
  labels:
    app: gitea
spec:
  replicas: 1
  serviceName: gitea-service-headless
  selector:
    matchLabels:
      app: gitea
  template:
    metadata:
      labels:
        app: gitea
    spec:
      containers:
      - name: gitea
        image: gitea/gitea:1.12.2
        ports:
        - containerPort: 3000
          name: gitea
        - containerPort: 22
          name: git-ssh
        volumeMounts:
        - name: pv-data
          mountPath: /data
      volumes:
      - name: pv-data
        persistentVolumeClaim:
            claimName: gitea-pvc
</code></pre>
<pre><code>apiVersion: v1
kind: Service
metadata:
  name: gitea-service-headless
  labels:
    app: gitea-service-headless
spec:
  clusterIP: None
  ports:
  - port: 3000
    name: gitea-http
    targetPort: 3000
  - port: 22
    name: gitea-https
    targetPort: 22    
  selector:
    app: gitea
</code></pre>

Jayson Gonzaga
<blockquote>
<p>I'm wondering why I only got this error every time i reboot my device.</p>
</blockquote>
<p>Well, lets look at the error:</p>
<blockquote>
<p>Error updating Endpoint Slices for Service dev-ops/gitea-service: node &quot;rpi4-a&quot; not found</p>
</blockquote>
<p>It look like the error was triggered because: <code>node &quot;rpi4-a&quot; not found</code>. Why is it not found?? While rebooting, the node is down, pod is not working for a moment and this is when service throws the error. When the node boots up, pod starts working but the events are present for one hour (by default) before they get automatically deleted.</p>
<p>So don't worry about it. You rebooted the node so you should expect some errors to appear. Kubernetes tries as hard as it can to keep everything working, so when you trigger the reboot without draining the node, some errors may appear.</p>
