spire-tutorials icon indicating copy to clipboard operation
spire-tutorials copied to clipboard

Tutorial fails when installing spire server

Open Ruoyu-y opened this issue 3 years ago • 3 comments

Installation failure while using the yamls within the repo to bootstrap spire server

Statefulset:

kubectl get statefulsets.apps -n spire
NAME           READY   AGE
spire-server   0/1     7m27s
kubectl describe statefulsets.apps -n spire spire-server
Name:               spire-server
Namespace:          spire
CreationTimestamp:  Thu, 13 Oct 2022 11:39:52 -0400
Selector:           app=spire-server
Labels:             app=spire-server
Annotations:        <none>
Replicas:           1 desired | 1 total
Update Strategy:    RollingUpdate
  Partition:        0
Pods Status:        0 Running / 1 Waiting / 0 Succeeded / 0 Failed
Pod Template:
  Labels:           app=spire-server
  Service Account:  spire-server
  Containers:
   spire-server:
    Image:      gcr.io/spiffe-io/spire-server:1.2.3
    Port:       8081/TCP
    Host Port:  0/TCP
    Args:
      -config
      /run/spire/config/server.conf
    Liveness:     http-get http://:8080/live delay=15s timeout=3s period=60s #success=1 #failure=2
    Readiness:    http-get http://:8080/ready delay=5s timeout=1s period=5s #success=1 #failure=3
    Environment:  <none>
    Mounts:
      /run/spire/config from spire-config (ro)
      /run/spire/data from spire-data (rw)
  Volumes:
   spire-config:
    Type:      ConfigMap (a volume populated by a ConfigMap)
    Name:      spire-server
    Optional:  false
Volume Claims:
  Name:          spire-data
  StorageClass:
  Labels:        <none>
  Annotations:   <none>
  Capacity:      1Gi
  Access Modes:  [ReadWriteOnce]
Events:
  Type    Reason            Age    From                    Message
  ----    ------            ----   ----                    -------
  Normal  SuccessfulCreate  5m32s  statefulset-controller  create Claim spire-data-spire-server-0 Pod spire-server-0 in StatefulSet spire-server success
  Normal  SuccessfulCreate  5m32s  statefulset-controller  create Pod spire-server-0 in StatefulSet spire-server successful
kubectl describe persistentvolumeclaims -n spire
Name:          spire-data-spire-server-0
Namespace:     spire
StorageClass:
Status:        Pending
Volume:
Labels:        app=spire-server
Annotations:   <none>
Finalizers:    [kubernetes.io/pvc-protection]
Capacity:
Access Modes:
VolumeMode:    Filesystem
Used By:       spire-server-0
Events:
  Type    Reason         Age                   From                         Message
  ----    ------         ----                  ----                         -------
  Normal  FailedBinding  3m15s (x42 over 13m)  persistentvolume-controller  no persistent volumes available for this claim and no storage class is set

Kubernetes version:

Client Version: version.Info{Major:"1", Minor:"23", GitVersion:"v1.23.3", GitCommit:"816c97ab8cff8a1c72eccca1026f7820e93e0d25", GitTreeState:"clean", BuildDate:"2022-01-25T21:25:17Z", GoVersion:"go1.17.6", Compiler:"gc", Platform:"linux/amd64"}
Server Version: version.Info{Major:"1", Minor:"23", GitVersion:"v1.23.3", GitCommit:"816c97ab8cff8a1c72eccca1026f7820e93e0d25", GitTreeState:"clean", BuildDate:"2022-01-25T21:19:12Z", GoVersion:"go1.17.6", Compiler:"gc", Platform:"linux/amd64"}

Ruoyu-y avatar Oct 13 '22 07:10 Ruoyu-y

What kind of k8s environment are you deploying into?

Normal FailedBinding 3m15s (x42 over 13m) persistentvolume-controller no persistent volumes available for this claim and no storage class is set

This error message seems relevant.

azdagron avatar Oct 18 '22 16:10 azdagron

What kind of k8s environment are you deploying into?

Normal FailedBinding 3m15s (x42 over 13m) persistentvolume-controller no persistent volumes available for this claim and no storage class is set

This error message seems relevant.

This is the kubernetes build based on kubeadm and using version 1.23.3

Ruoyu-y avatar Jan 06 '23 02:01 Ruoyu-y

as stated i tried image

apiVersion: v1
kind: PersistentVolume
metadata:
  name: spire-data
  labels:
    type: local
spec:
  accessModes:
    - ReadWriteOnce
  capacity:
    storage: 100Mi
  hostPath:
    path: "/run/spire/data"

ramkumar-equinix avatar Nov 01 '23 07:11 ramkumar-equinix