Get A Quote

Book A Demo

Configure Docker Remote API

1 min read

Overview #

NiralOS EDGE communicates with Docker Engine through the Docker Remote API.

This guide explains how to enable the Docker Remote API with or without TLS on Linux and Windows.

Recommendation

Use TLS in production environments. Non-TLS mode should only be used on trusted internal networks or for testing purposes.

Enable Docker Remote API Without TLS #

Linux #

Create the Docker systemd override directory.

sudo mkdir -p /etc/systemd/system/docker.service.d

Create an override configuration.

sudo nano /etc/systemd/system/docker.service.d/override.conf

Add the following configuration.

[Service]

ExecStart=

ExecStart=/usr/bin/dockerd \

    -H fd:// \

    -H tcp://0.0.0.0:2375

Reload systemd and restart Docker.

sudo systemctl daemon-reload
sudo systemctl restart docker

Verify the API.

curl http://:2375/version

Windows (Docker Desktop) #

  1. Open Docker Desktop. 
  2. Navigate to Settings → General. 
  3. Enable Expose daemon on tcp://localhost:2375 without TLS. 
  4. Click Apply & Restart. 

Note

By default, Docker Desktop exposes the API only on localhost. Additional Windows Firewall and networking configuration is required for remote access.

Enable Docker Remote API with TLS #

For production deployments, configure Docker Engine with TLS.

Generate the following certificates:

  • Certificate Authority (CA) 
  • Server Certificate 
  • Server Private Key 

Configure Docker Engine to start with:

  • –tlsverify
  • –tlscacert=<CA Certificate>
  • –tlscert=<Server Certificate>
  • –tlskey=<Server Private Key>
  • -H tcp://0.0.0.0:2376

Restart Docker Engine.

Recommended Ports #

ModePort
Non-TLS2375
TLS2376

Troubleshooting #

Unable to Connect #

Verify:

  • Docker Engine is running. 
  • The API port is reachable. 
  • Windows Firewall or Linux firewall allows inbound connections. 
  • The correct IP address and port are being used.

TLS Connection Failed #

Verify:

  • The uploaded CA certificate matches the server certificate. 
  • Docker Engine is configured with –tlsverify. 
  • The client is connecting to the correct port (2376).