Error while trying to install Kasm WorkSpaces:
# docker run -d –name kasm_workspaces –restart unless-stopped \
–privileged \
-p 8443:8443 -p 443:443 -p 80:80 \
kasmweb/workspaces:1.16.1
7bb226afcb81f70f21cadf80cc8de001b4d30e37152436baecd8d8a0b456f736
docker: Error response from daemon: driver failed programming external connectivity on endpoint kasm_workspaces (533e7b6ff27e860d8707990c301086cf7daa35d6f424eac00a27cb646ba2976e): Bind for 0.0.0.0:443 failed: port is already allocated.
The error message indicates that port 443 is already in use by another service on your host machine. To resolve this, you can either stop the service using port 443 or map the Kasm Workspaces container to a different port on the host. Step 1: Identify the Service Using Port 443
- Check for Services Using Port 443
# sudo netstat -tuln | grep 443
This command will show you which service is using port 443.
- Stop the Service Using Port 443 (if possible) If you identify a service that can be stopped, use the appropriate command to stop it. For example, if Nginx is using port 443:
# sudo systemctl stop nginx
Step 2: Run the Container with a Different Host Port If stopping the service using port 443 is not an option, you can map the Kasm Workspaces container to a different port on the host.
- Run the Container with a Different Host Port
# docker run -d --name kasm_workspaces --restart unless-stopped \ --privileged \ -p 8443:8443 -p 10443:443 -p 80:80 \ kasmweb/workspaces:1.16.1
In this example, the container’s port 443 is mapped to host port 10443 to avoid conflicts.