AgustinCB / docker-api

Docker Remote API driver for node.js. It uses the same modem than dockerode, but the interface is promisified and with a fancier syntax.
GNU General Public License v3.0
303 stars 51 forks source link

Example needed 'add-host' #74

Open StephanBeutel opened 2 years ago

StephanBeutel commented 2 years ago

In my docker run command I have to use this:

--add-host=host.docker.internal:host-gateway

How can I achieve the same functionality in docker.container.create? Right now my code looks like this:

                docker.container.create({
                    Image: 'IMAGENAME',
                    name: bot_name,
                    Env: [envChannel],
                    HostConfig: {
                        Binds: [
                            envFolder + ":" + envLogFolder
                        ]
                    }
                })