Tacot
Tacot

Reputation: 194

Kubernetes run pod as root

I am trying to deploy the Hashicorp Vault Helm chart, and I get the following issue: Error: container's runAsUser breaks non-root policy is there a way to run Vault as non root? or is there a way to only allow that service to run as root without changing the whole policy?

Upvotes: 1

Views: 3656

Answers (2)

Tacot
Tacot

Reputation: 194

found the issue, it was in the same namespace as my Azure Dev Spaces and there was a conflict there, moved to a new namespace and it was fixed

Upvotes: 2

Yuri Oliveira
Yuri Oliveira

Reputation: 44

The test container that's the base of the Helm Chart currently works with the directory in /root. So you must run the Chart with root or you will have to change the Chart completely.

FROM alpine:latest
WORKDIR /root

ENV BATS_VERSION "1.1.0"

# base packages
RUN apk update && apk add --no-cache --virtual .build-deps \
    ca-certificates \
    curl \
    tar \
    bash \
    openssl \
    python \
    py-pip \
    git \
    jq

Upvotes: 0

Related Questions