Some Dinosaur
Some Dinosaur
CCoder.com
Created by Some Dinosaur on 1/20/2025 in #help
Docker in workspace
I can't seem to run docker containers inside a running workspace. I get an error:
service docker start
/etc/init.d/docker: 62: ulimit: error setting limit (Invalid argument)
service docker start
/etc/init.d/docker: 62: ulimit: error setting limit (Invalid argument)
Is running a docker inside a running VSCode server supported?
6 replies
CCoder.com
Created by Some Dinosaur on 1/4/2025 in #help
Coder ran on a machine with VPN can't resolve the hostname
I moved Coder to run on my main system which has a Proton VPN up and running. It's a regular Ubuntu. So when I run Coder (through docker compose), starting a workspace doesn't work. My workspace container logs:
+ curl -fsSL --compressed http://funny_hostname:7080/bin/coder-linux-amd64 -o coder
curl: (6) Could not resolve host: funny_hostname
+ status=6
+ echo error: failed to download coder agent
+ echo command returned: 6
+ echo Trying again in 30 seconds...
+ sleep 30
error: failed to download coder agent
+ curl -fsSL --compressed http://funny_hostname:7080/bin/coder-linux-amd64 -o coder
curl: (6) Could not resolve host: funny_hostname
+ status=6
+ echo error: failed to download coder agent
+ echo command returned: 6
+ echo Trying again in 30 seconds...
+ sleep 30
error: failed to download coder agent
Once I disable the VPN, it finds host from the container:
root ➜ / $ ping funny_hostname
PING funny_hostname (192.168.0.31) 56(84) bytes of data.
64 bytes from funny_hostname (192.168.0.31): icmp_seq=1 ttl=64 time=0.045 ms
64 bytes from funny_hostname (192.168.0.31): icmp_seq=2 ttl=64 time=0.030 ms
root ➜ / $ ping funny_hostname
PING funny_hostname (192.168.0.31) 56(84) bytes of data.
64 bytes from funny_hostname (192.168.0.31): icmp_seq=1 ttl=64 time=0.045 ms
64 bytes from funny_hostname (192.168.0.31): icmp_seq=2 ttl=64 time=0.030 ms
What options do I have? I'd love to split tunnel the VPN so that Coder doesn't use it - but I don't know how to do it.
6 replies
CCoder.com
Created by Some Dinosaur on 12/25/2024 in #help
Set "extensions" and "theme" from `devcontainer.json`
I'm trying to use the default template Docker (Devcontainer) and I was hoping I'd be able to hold every piece of information of how to set up the environment in the repository and not the template itself. I have a template to just pull a GitHub repo and set it up however it wants, using it's .devcontainer/Dockerfile and .devcontainer/devcontainer.json. I'm having problems with pulling extensions and setting the theme for the code-server. I was hoping that I could just set it from the devcontainer.json but it doesn't work - neither settings or extensions are taken into consideration when building the Workspace. Here's my devcontainer.json:
{
"name": "Test Backend",
"build": {
"dockerfile": "./Dockerfile",
"context": "."
},
"features": {
"ghcr.io/devcontainers/features/common-utils:2": {
"installZsh": "true",
"username": "vscode",
"userUid": "1000",
"userGid": "1000",
"upgradePackages": "true"
},
"ghcr.io/devcontainers/features/rust:1": "latest",
"ghcr.io/devcontainers/features/git:1": {
"version": "latest",
"ppa": "false"
}
},
"customizations": {
"vscode": {
"settings": {
"workbench.colorTheme": "Visual Studio Dark"
},
"extensions": [
"rust-lang.rust-analyzer"
]
}
},
"forwardPorts": []
}
{
"name": "Test Backend",
"build": {
"dockerfile": "./Dockerfile",
"context": "."
},
"features": {
"ghcr.io/devcontainers/features/common-utils:2": {
"installZsh": "true",
"username": "vscode",
"userUid": "1000",
"userGid": "1000",
"upgradePackages": "true"
},
"ghcr.io/devcontainers/features/rust:1": "latest",
"ghcr.io/devcontainers/features/git:1": {
"version": "latest",
"ppa": "false"
}
},
"customizations": {
"vscode": {
"settings": {
"workbench.colorTheme": "Visual Studio Dark"
},
"extensions": [
"rust-lang.rust-analyzer"
]
}
},
"forwardPorts": []
}
38 replies
CCoder.com
Created by Some Dinosaur on 12/23/2024 in #help
Failed to pull GitHub private repo
I know this has been asked before - but I absolutely don't get how to solve it from the responds. I got the SSH key from SSH keys settings, pasted it to my SSH keys on GitHub. I use the Devcontainer template, with my own repository URL. I keep getting an error:
envbuilder v1.1.0+a3a6a83 - Build development environments from repositories in a container
#1: 📦 Cloning [email protected]:MyUsername/my-repository.git to /workspaces/my-repository...
#1: 🔑 Using SSH authentication!
#1: 🔑 No SSH key found, falling back to agent!
#1: ❌ Failed to connect to SSH agent: error creating SSH agent: "SSH agent requested but SSH_AUTH_SOCK not-specified"
#1: Parsed Git URL as "ssh://[email protected]/MyUsername/my-repository.git"
Failed to clone repository: clone "[email protected]:MyUsername/my-repository.git": error creating SSH agent: "SSH agent requested but SSH_AUTH_SOCK not-specified"
Falling back to the default image...
envbuilder v1.1.0+a3a6a83 - Build development environments from repositories in a container
#1: 📦 Cloning [email protected]:MyUsername/my-repository.git to /workspaces/my-repository...
#1: 🔑 Using SSH authentication!
#1: 🔑 No SSH key found, falling back to agent!
#1: ❌ Failed to connect to SSH agent: error creating SSH agent: "SSH agent requested but SSH_AUTH_SOCK not-specified"
#1: Parsed Git URL as "ssh://[email protected]/MyUsername/my-repository.git"
Failed to clone repository: clone "[email protected]:MyUsername/my-repository.git": error creating SSH agent: "SSH agent requested but SSH_AUTH_SOCK not-specified"
Falling back to the default image...
32 replies