Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

212
Views
Kubernetes Pod mount /var/run/docker.sock and use imagePullSecrets

I assign an imagePullSecrets to my pod which allows the pod(?) to pull an image for a container from a private registry:

spec:
  imagePullSecrets:
  - name: dockerrep

This works great. Now in my pod spec I do pass the docker instance down with:

spec:
  volumes:
  - name: dockersock
    hostPath:
      path: /var/run/docker.sock

This way I can use docker inside my container! (I also mount it inside the container). But inside my container the docker instance is not allowed to pull using the imagePullSecrets provided to the pod itself.

Does anyone know if there is a direct way to do this? I thought that the docker instance (that's "passed down") into the container would automatically inherit the "docker login" from the imagePullSecret.

I know I can mount the pull secret manually again inside my container and perform a "docker login", just wanting to know if there is a direct way.

Thanks.

over 4 years ago · Santiago Trujillo
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!