Mirantis / Mirantis/cri-dockerd
Custom HTTP Headers in requests towards dockerd
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 1.4k
- Forks
- 356
- Avg merge
- 4d 4h
- Merged PRs (30d)
- 3
Description
I'm trying to install Kubernetes v1.25 on a machine with Docker 20.10.21 with opa-docker-authz-v2:0.4 as an active plugin.
I installed cri-dockerd following the guide, unfortunately, I can't find a way to specify HTTP headers in the requests that cri-dockerd forwards to the dockerd and this results in OPA denying these requests.
Kubeadm init command fails because it cannot pull images (but I overcame this by pulling images by hand with docker pull) or start containers.
I tried to make a small-scale example to show what's happening:
Logs from journalctl -xeu docker.service:
Output from docker image ls, docker specifies Authz fields in the headers:

Then I created example.yaml:
apiVersion: v1
kind: Pod
metadata:
name: test
labels:
role: testingpod
spec:
containers:
- name: test
image: python:3.6
And launched it crictl --debug --runtime-endpoint unix:///var/run/cri-dockerd.sock runp example.yaml
The resulting output from journalctl -xeu docker.service:


In this case, the header does not contain any of the Authz fields required by OPA so the request is rejected.
Is there a way to specify headers in cri-dockerd configuration?
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
No source files or tests are named. Start by tracing the cri-dockerd configuration and the CRI request path exercised by crictl ... runp example.yaml, then determine how requests reach dockerd. Done means the forwarded requests include the required authorization headers and the demonstrated pod or kubeadm workflow succeeds.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- docker, go
- Domain
- infrastructure
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100