Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How do I run docker inside a function? #1706

Closed
5 tasks
mrunmayi opened this issue Mar 29, 2022 · 3 comments
Closed
5 tasks

How do I run docker inside a function? #1706

mrunmayi opened this issue Mar 29, 2022 · 3 comments

Comments

@mrunmayi
Copy link

My actions before raising this issue

  • Followed the troubleshooting guide verified issue not mentioned in troubleshooting guide
  • Read/searched the docs already read the docs
  • Searched past issues : yes I searched past issues and could not find similar issue.

Expected Behaviour

There are currently 3 ways to run docker inside docker (https://devopscube.com/run-docker-in-docker/)

  • By mounting docker.sock: As faas does container management we are unable to mount the docker in the existing containers that faas-deploy created. we could not find any such option to mount a socket
  • By using dind which needs privileged mode to containers. I saw in few of the issues (Feature: add privileged supported in function #1238) its mentioned that openfaas do not plan to support privileged mode to containers
  • By Sysbox : I coud not find any documentation around it ini openfaas.

we should be allowed to docker command like docker build inside the docker container

Current Behaviour

currently we do not have any way or much documentation around how to run docker commands inside faas manages containers

Are you a GitHub Sponsor (Yes/No?) : no

Check at: https://github.com/sponsors/openfaas

  • Yes
  • No

List All Possible Solutions and Workarounds

Which Solution Do You Recommend?

Steps to Reproduce (for bugs)

  1. build an image
  2. use faas-cli deploy to deploy the image
  3. login into the container / try to run docker command
  4. it fails

Context

We have a cli micro-service which is running using openfaas. This service try to build docker images and deploy the images for other product components

Your Environment

  • FaaS-CLI version ( Full output from: faas-cli version ):

  • Docker version docker version (e.g. Docker 17.0.05 ):

  • Are you using OpenFaaS on Kubernetes or faasd?

  • Operating System and version (e.g. Linux, Windows, MacOS):

  • Code example or link to GitHub repo or gist to reproduce problem:

  • Other diagnostic information / logs from troubleshooting guide

@alexellis
Copy link
Member

@mrunmayi

Thanks for your interest, however it's unclear what you're trying to do and why.

Please take a few steps back and explain why you want to use docker in a container.

@alexellis
Copy link
Member

/add label: support,question

@alexellis alexellis changed the title Run docker command inside the openfass/fass created docker container How do I run docker inside a function? Apr 12, 2022
@alexellis
Copy link
Member

Closing since we didn't hear back from you.

Feel free to send another comment here if you want to continue the discussion.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants