When we start a container with --net=host (which is possible in the latest docker-plugin of Jenkins), then the port bindings is empty.
When the container is created, the Ports is correctly deserialize with the binding. However, when trying to access the container details, the NetworkMode is correct, but the library doesn't deserialize the binding correctly.
Feel free to provide PR. Also running container with net=host sounds stupid.
I think this is expected. When using host networking there is no longer a concept of port bindings.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.