Coder workspace creation failing

518 views Asked by At

I am trying to set up Coder via Docker with docker-compose.

I defined it as a service in my docker-compose.yml (based on this in-line command):

version: "3.6"

services:
  coder:
    image: codercom/coder:1.35.0
    ports:
      - "7080:7080"
    group_add:
      - 134 # added docker group for write permissions
    volumes:
      - /var/run/docker.sock:/var/run/docker.sock
      - /srv/databases/docker/data/volumes/coder:/var/run/coder

The UI is then accessible and I can login with the provided credentials, but when I try to create a workspace, the process fails in step 11: create workspace: Failed to create Container-based Virtual Machine: start boots

create workspace: Failed to create Container-based Virtual Machine: start bootstrap: execute bootstrap failed: docker exec: exec cmd "/usr/bin/docker exec -i -u 1000 coder /bin/sh -s": exit status 28

For the workspace I defined the image "codercom/enterprise-jupyter", listed under the pre-defined "Packaged" section.

The workspace provider by default is Docker.

What is going wrong and how can I fix it?

How it looks in the UI:

enter image description here

Update:

I found out, that a container is being created for the environment:

CONTAINER ID   IMAGE                           COMMAND                  CREATED              STATUS                  PORTS                                                                                                                                                            NAMES
f06eb1365588   coderenvs/envbox:1.35.0-rc.2    "/envbox legacy"         About a minute ago   Up About a minute                                                                                                                                                                        goofy_noether
db2666b7bdf9   codercom/coder:1.35.0           "/coderd run --bind …"   2 minutes ago        Up About a minute       5432/tcp, 0.0.0.0:7080->7080/tcp, :::7080->7080/tcp                                                                                                              infrastructure-management_coder_1

Inspecting the log via docker logs f06eb1365588 shows an error message:

{"ts":"2023-02-23T09:56:09.937651147Z","level":"ERROR","msg":"child log","logger_name":"sysbox-fs","fields":{"process":"sysbox-fs","content":"time=\"2023-02-23 09:56:09\" level=error msg=\"Failed to write to /proc/sys/net/core/default_qdisc: open /proc/sys/net/core/default_qdisc: no such file or directory\""}}
1

There are 1 answers

0
Kim Tang On BEST ANSWER

It did not exactly solve this issue, but I was able to create workspaces with coder/coder version 2, not version 1.

I used docker-compose for that as references by the documentation: https://github.com/coder/coder/blob/main/docker-compose.yaml