PHPackages                             polkovnik-z/php-docker-client - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [DevOps &amp; Deployment](/categories/devops)
4. /
5. polkovnik-z/php-docker-client

Abandoned → [ibra-akv/php-docker-client](/?search=ibra-akv%2Fphp-docker-client)Library[DevOps &amp; Deployment](/categories/devops)

polkovnik-z/php-docker-client
=============================

Docker API driver for PHP.

3.41.3(3y ago)21.7k1MITPHPPHP &gt;=7.1.3

Since Mar 22Pushed 3y ago2 watchersCompare

[ Source](https://github.com/ibra-akv/php-docker-client)[ Packagist](https://packagist.org/packages/polkovnik-z/php-docker-client)[ Docs](https://github.com/ibra-akv/php-docker-client)[ RSS](/packages/polkovnik-z-php-docker-client/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (7)Dependencies (4)Versions (11)Used By (1)

PHP Docker client
=================

[](#php-docker-client)

[![CircleCI](https://camo.githubusercontent.com/9994da271d82fad6c80cfcab55073bdab031018d901a189bf38dd9cea2513286/68747470733a2f2f646c2e636972636c6563692e636f6d2f7374617475732d62616467652f696d672f67682f696272612d616b762f7068702d646f636b65722d636c69656e742f747265652f6d61737465722e7376673f7374796c653d737667)](https://dl.circleci.com/status-badge/redirect/gh/ibra-akv/php-docker-client/tree/master)[![Coverage Status](https://camo.githubusercontent.com/6a8412fc49d759f7a59b45f3be85c56b0497faae628d59bb45b06b54e210907e/68747470733a2f2f636f766572616c6c732e696f2f7265706f732f6769746875622f696272612d616b762f7068702d646f636b65722d636c69656e742f62616467652e7376673f6272616e63683d6d6173746572266b696c6c5f63616368653d31)](https://coveralls.io/github/ibra-akv/php-docker-client?branch=master)

> Docker API driver for PHP.

Docker configuration
--------------------

[](#docker-configuration)

Docker Engine API must be exposed on a local port in order to be able to connect.

##### 1. Edit the `docker.service` which by default on debian is located at `/lib/systemd/system/docker.service`

[](#1-edit-the-dockerservice-which-by-default-on-debian-is-located-at-libsystemdsystemdockerservice)

From this:

```
# /lib/systemd/system/docker.service
...
ExecStart=/usr/bin/dockerd -H fd:// --containerd=/run/containerd/containerd.sock
...
```

To this:

```
# /lib/systemd/system/docker.service
...
ExecStart=/usr/bin/dockerd
...
```

##### 2. Edit `/etc/docker/daemon.json` to expose docker api at `127.0.0.1:2375`

[](#2-edit-etcdockerdaemonjson-to-expose-docker-api-at-1270012375)

Add `hosts` to the json file as next:

```
{
  ...
  "hosts": ["fd://", "tcp://127.0.0.1:2375"]
  ...
}
```

##### 3. Restart Docker completely

[](#3-restart-docker-completely)

```
systemctl daemon-reload
systemctl restart docker
service docker restart
```

Installation
------------

[](#installation)

```
composer require ibra-akv/php-docker-client

```

Usage
-----

[](#usage)

Initialize client

```
use IterativeCode\Component\DockerClient\DockerClient;

$docker = new DockerClient([
    'local_endpoint' => 'http://localhost:2375/v1.41', # Optional (default: http://localhost:2375)
]);
```

Check if image exists

```
$exists = $docker->imageExists('436aed837ea2');
# true | false

$details = $docker->inspectImage('436aedXXXXXX');
# array | @throws Exception
```

API Reference
-------------

[](#api-reference)

- #### [DockerClient](docs/DockerClient.md)

    [](#dockerclient)

Tested Docker versions
----------------------

[](#tested-docker-versions)

- #### [1.41](https://docs.docker.com/engine/api/v1.41/)

    [](#141)

License
-------

[](#license)

- [Review](LICENSE)

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity18

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity53

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~79 days

Recently: every ~10 days

Total

8

Last Release

1322d ago

Major Versions

1.41.13 → 2.41.02022-08-17

2.x-dev → 3.41.02022-08-19

### Community

Maintainers

![](https://www.gravatar.com/avatar/989951d5184b459a3a842d869b2f3f814a391a716ba5dba717a875cb31199466?d=identicon)[ibra-akv](/maintainers/ibra-akv)

---

Top Contributors

[![0xIbra](https://avatars.githubusercontent.com/u/47257235?v=4)](https://github.com/0xIbra "0xIbra (90 commits)")

---

Tags

dockerdocker-apidocker-driverdocker-sdk-phpphp

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/polkovnik-z-php-docker-client/health.svg)

```
[![Health](https://phpackages.com/badges/polkovnik-z-php-docker-client/health.svg)](https://phpackages.com/packages/polkovnik-z-php-docker-client)
```

###  Alternatives

[shopware/deployment-helper

Shopware deployment tools

19305.3k5](/packages/shopware-deployment-helper)[symfony-tools/docs-builder

The build system for Symfony's documentation

3663.3k1](/packages/symfony-tools-docs-builder)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
