Skip to content

Fleet container fails: /var/run/secrets/kubernetes.io/serviceaccount/token: permission denied #790

@patrijua

Description

@patrijua

With Rancher v2.6.3 running in AWS EKS with kubernetes version 1.21, fleet fails to reconcile the downstream cluster because "fleet" container fails. Previous "step-git-source" is successful and clones the git repository.

containerStatuses:
 - name: fleet
state:
terminated:
exitCode: 1
reason: Error
message: >
 time="2022-06-08T11:46:40Z" level=fatal msg="open
 /var/run/secrets/kubernetes.io/serviceaccount/token: permission
 denied"

Seems that the user running the pod (1000) does not have access to token. I did a test by modifying the pod definition to run as root and triggered the pod manually, then fleet container was ran successfully.

  securityContext:
    runAsUser: 0

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions