qJake / HADotNet.CommandCenter

📱 A web-based, wall-mountable command center for Home Assistant.
https://hacc.dev
Apache License 2.0
158 stars 11 forks source link

error on starting #96

Closed jruibarroso closed 4 years ago

jruibarroso commented 4 years ago

Description

sudo docker run -p 8095:8095 qjake/hacc docker: Error response from daemon: driver failed programming external connectivity on endpoint clever_mestorf (c30894ec775c15e953abe239a068af92f1765ec4d72e8f19440452a16afb116b): Bind for 0.0.0.0:8095 failed: port is already allocated. ERRO[0000] error waiting for container: context canceled

Environment

<What version of HACC are you running?> 1.018 <What environment is it? Hass.io on a Raspberry Pi 3B+? AMD64 Docker on Alpine 3.10?> Ubuntu 18.04

Steps to Reproduce

  1. List out the
  2. Steps to take to
  3. Reproduce the issue

Screenshots

sudo docker run -p 8095:8095 qjake/hacc docker: Error response from daemon: driver failed programming external connectivity on endpoint clever_mestorf (c30894ec775c15e953abe239a068af92f1765ec4d72e8f19440452a16afb116b): Bind for 0.0.0.0:8095 failed: port is already allocated. ERRO[0000] error waiting for container: context canceled
qJake commented 4 years ago

Port 8095 is already in use. Use docker ps to find your running container, and docker stop <first few characters of your containter ID> to stop it. Then you can do docker run.

But if you're just trying to upgrade to a new version, see the instructions on our new (beta) site here: Updaing HACC - essentially, you want to stop, pull, and start.

Here's a full log demonstrating the problem and the fix:

PS C:\> docker ps
CONTAINER ID        IMAGE               COMMAND                  CREATED             STATUS              PORTS                    NAMES
35c38b96bfe7        qjake/hacc:1.0.4    "dotnet HADotNet.Com…"   2 days ago          Up 33 seconds       0.0.0.0:8095->8095/tcp   hacc
PS C:\> docker run -p 8095:8095 qjake/hacc
C:\Program Files\Docker\Docker\resources\bin\docker.exe: Error response from daemon: driver failed programming external connectivity on endpoint happy_montalcini (bcdf9095f8ad16ffef806938b8c9c1aa4a3964b9f74c13f0759c3bc05cfe07ea): Bind for 0.0.0.0:8095 failed: port is already allocated.
PS C:\> docker stop 35c38
35c38
PS C:\> docker ps
CONTAINER ID        IMAGE               COMMAND             CREATED             STATUS              PORTS               NAMES
PS C:\> docker run -p 8095:8095 qjake/hacc
info: HADotNet.CommandCenter.Startup[0]

        _    _          _____ _____
       | |  | |   /\   / ____/ ____|
       | |__| |  /  \ | |   | |
       |  __  | / /\ \| |   | |
       | |  | |/ ____ \ |___| |____
       |_|  |_/_/    \_\_____\_____|

       Home Assistant Command Center
              Version 1.0.19

      Now listening on: http://*:8095