docker postgres pgadmin local connection

前端 未结 16 2316
清歌不尽
清歌不尽 2020-12-02 06:44

I have created an ubuntu image with nginx, php and postgres.

I want to connect the postgres database in my current image with pgadmin located on my loca

16条回答
  •  没有蜡笔的小新
    2020-12-02 07:04

    In order or find your IP of the container, use following command

    docker inspect -f '{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' container_name_or_id
    

    Referrence: How to get a Docker container's IP address from the host

提交回复
热议问题