{% extends "portregistry/base.html" %} {% load pr_format %} {% block title %}Containers{% endblock %} {% block heading %}Docker containers{% endblock %} {% block content %} {% if pr_docker %} {% if pr_docker.state == "disabled" %}
Docker discovery is disabled in the configuration.
{% elif pr_docker.state != "ok" %}
Docker discovery is {{ pr_docker.state }}: {{ pr_docker.message|default:"no details" }} Native socket discovery is unaffected.{% if rows %} Containers below are the last known state{% if pr_docker.last_success %} from {{ pr_docker.last_success|ago }}{% endif %} and may be out of date.{% endif %}
{% else %}

Docker {{ pr_docker.details.server_version|default:"" }} · last inventory {{ pr_docker.last_success|ago }}. PortRegistry only reads from Docker; it never starts, stops or executes anything in containers.

{% endif %} {% endif %}
Present Include removed
{% for c in rows %} {% empty %} {% endfor %}
ContainerImageStatusPublished (host → container)Internal onlyNetworksStarted
{{ c.name }}
{{ c.short_id }}
{{ c.image_ref }} {% if c.present %}{{ c.status }}{% else %}removed{% endif %} {% for m in c.port_mappings.all %}{% if m.published and m.active %}{{ m.host_ip|default:"0.0.0.0" }}:{{ m.host_port }} → {{ m.container_port }}/{{ m.protocol }}
{% endif %}{% endfor %}
{% for m in c.port_mappings.all %}{% if not m.published %}{{ m.container_port }}/{{ m.protocol }} {% endif %}{% endfor %} {% for name in c.networks %}{{ name }}{% if not forloop.last %}, {% endif %}{% endfor %} {{ c.started_at|ago }}
{% if pr_docker.state == "ok" %}No containers.{% else %}No container data (Docker has not been reachable).{% endif %}

Internal container ports, host-published mappings and host-visible sockets are distinct: a published mapping is reported by Docker, while the host socket (on the Ports page) may be owned by a Docker proxy process rather than the container's own process.

{% endblock %}