By using this site, you agree to the Privacy Policy and Terms of Use.
Accept
IT Infras HolicIT Infras HolicIT Infras Holic
  • News
  • Linux
    • Application
    • SELinux
    • Centos
    • Ubuntu
  • Docker
  • Web Server
    • Kong
    • Nginx
    • Openlitespeed
  • Database
  • Mikrotik
  • Windows
  • Mail
  • Tools
    • 2048
    • Fantasy Forest
    • Hextris
    • Crossword
Search
  • Privacy Policy
© 2024. All Rights Reserved.
Font ResizerAa
IT Infras HolicIT Infras Holic
Font ResizerAa
  • News
  • Linux
  • Docker
  • Web Server
  • Database
  • Mikrotik
  • Windows
  • Mail
  • Tools
Search
  • News
  • Linux
    • Application
    • SELinux
    • Centos
    • Ubuntu
  • Docker
  • Web Server
    • Kong
    • Nginx
    • Openlitespeed
  • Database
  • Mikrotik
  • Windows
  • Mail
  • Tools
    • 2048
    • Fantasy Forest
    • Hextris
    • Crossword
Follow US
© 2022 Foxiz News Network. Ruby Design Company. All Rights Reserved.
IT Infras Holic > Blog > Docker > How to Enable Docker Remote API
Docker

How to Enable Docker Remote API

writer
Share
1 Min Read
SHARE

How to Enable Docker Remote API

Docker Engine exposes a REST API which you can use to control your containers without the docker CLI. The API exposes equivalent functionality using HTTP network calls. You can script common Docker operations using your favorite programming language or remotely control one of your hosts. The CLI internally relies on the same API to provide its built-in commands.

Contents
How to Enable Docker Remote APIOpen docker.service located in /lib/systemd/systemPlace this belowSave the Modified FileReload the docker daemonRestart the containerTest if it is working

 

Here are how to Enable Docker Remote API

Open docker.service located in /lib/systemd/system

1
vi /lib/systemd/system/docker.service

Find the line which starts with ExecStart  and disable by putting # before

Place this below

1
ExecStart=/usr/bin/dockerd -H tcp://0.0.0.0:2375 -H unix:///var/run/docker.sock

Save the Modified File

Reload the docker daemon

1
sudo systemctl daemon-reload

Restart the container

1
sudo service docker restart

Test if it is working

if everything is fine below command should return a JSON

1
curl http://localhost:2375/images/json

 

 

You Might Also Like

How to Clear Docker Logs and Activate Log Rotate

Install Kong Konga using Docker Compose

How to Change Docker Timezone

Install Docker CE on CentOS 7

TAGGED: docker, docker api
Share This Article
Facebook Twitter Whatsapp Whatsapp LinkedIn Telegram Copy Link
Previous Article Install Docker CE on CentOS 7 Install Docker CE on CentOS 7
Next Article How to Uninstall CloudMonitor Agent (Alibaba CLoud) How to Uninstall CloudMonitor Agent (Alibaba CLoud)
Leave a comment

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Latest News

bash
Monitoring File & Directory Changes using Bash Script
Linux Application
vulnerability
Vulnerability Checker CVE-2024-3094
Linux
wiki.js
Unleashing the Potential of Knowledge Management with Wiki.js
Application Linux
Install Apache Guacamole
How to Install Apache Guacamole with Docker Compose
Application Linux
Follow US
© 2024
activity notes activity notes
Welcome Back!

Sign in to your account

Lost your password?