Tom Thomson
Tom Thomson
CCoder.com
Created by Tom Thomson on 1/12/2023 in #help
CSS not loading when configured as app
Looks like this error happens on every app in coder that has subdomain = false
4 replies
CCoder.com
Created by Tom Thomson on 1/11/2023 in #help
Is it possible to enable networking between coder docker containers?
I found a solution where I created a new docker network using docker network create coder and then modified the template main.tf and added the following config to the container resource:
resource "docker_container" "workspace" {
...
networks_advanced {
name = "coder"
aliases = [ data.coder_workspace.me.name ]
}
}
resource "docker_container" "workspace" {
...
networks_advanced {
name = "coder"
aliases = [ data.coder_workspace.me.name ]
}
}
This makes the docker container available in the docker network "coder" and sets a network alias to the workspace name so you can reach it easly withoud needing to retrieve the containers ip address (which can potentialy change on restart)
22 replies
CCoder.com
Created by Tom Thomson on 1/12/2023 in #help
CSS not loading when configured as app
No description
4 replies
CCoder.com
Created by Scott on 1/12/2023 in #help
Avoid the double ssh entry locally?
No description
5 replies
CCoder.com
Created by Tom Thomson on 1/11/2023 in #help
Is it possible to enable networking between coder docker containers?
@Scott yes, correct
22 replies
CCoder.com
Created by Tom Thomson on 1/11/2023 in #help
After configuring the TLS-certificate in the coder config I can no longer reach the web ui
With caddy it works
12 replies
CCoder.com
Created by Tom Thomson on 1/11/2023 in #help
Is it possible to enable networking between coder docker containers?
Correct, I am trying to create a template to run mongodb databases inside a workspace.
22 replies
CCoder.com
Created by Tom Thomson on 1/11/2023 in #help
Is it possible to enable networking between coder docker containers?
I know that it's not possible to connect to mongodb via http. However I wanted to show that the server should be accessible. Maybe its not working because coder port forward only allows http(s) protocol and not others like https://www.mongodb.com/docs/manual/reference/mongodb-wire-protocol/
22 replies
CCoder.com
Created by Tom Thomson on 1/11/2023 in #help
Is it possible to enable networking between coder docker containers?
Yes thats possible, however you first need to configure the docker container to open the ports in the docker network.
22 replies
CCoder.com
Created by Tom Thomson on 1/11/2023 in #help
Is it possible to enable networking between coder docker containers?
I am currently running coder on a single ubuntu server with docker containers as workspaces.
22 replies
CCoder.com
Created by Tom Thomson on 1/11/2023 in #help
Is it possible to enable networking between coder docker containers?
Looks like when you access your mongodb server via http protocol it sends you a response. I wouldn't want to expose it to the public, but with port forward you would need to authentificate with your coder account. I don't think that would work. I am testing solutions to make it work in my current coder setup.
22 replies
CCoder.com
Created by Tom Thomson on 1/11/2023 in #help
After configuring the TLS-certificate in the coder config I can no longer reach the web ui
Thanks anyway
12 replies
CCoder.com
Created by Tom Thomson on 1/11/2023 in #help
Is it possible to enable networking between coder docker containers?
I tried no port (results in 27017) 443 and 80.
22 replies
CCoder.com
Created by Tom Thomson on 1/11/2023 in #help
Is it possible to enable networking between coder docker containers?
No description
22 replies
CCoder.com
Created by Tom Thomson on 1/11/2023 in #help
Is it possible to enable networking between coder docker containers?
And I set subdomain = true so mongo connecotrs wouldn't be confused by the url.
22 replies
CCoder.com
Created by Tom Thomson on 1/11/2023 in #help
Is it possible to enable networking between coder docker containers?
No description
22 replies
CCoder.com
Created by Tom Thomson on 1/11/2023 in #help
After configuring the TLS-certificate in the coder config I can no longer reach the web ui
No, this disables tls and when I access my workspaces I don't have ssl certificates.
12 replies
CCoder.com
Created by Tom Thomson on 1/11/2023 in #help
After configuring the TLS-certificate in the coder config I can no longer reach the web ui
With CODER_TLS_ENABLE=FALSE everything is working again.
12 replies
CCoder.com
Created by Tom Thomson on 1/11/2023 in #help
After configuring the TLS-certificate in the coder config I can no longer reach the web ui
No description
12 replies
CCoder.com
Created by Tom Thomson on 1/11/2023 in #help
After configuring the TLS-certificate in the coder config I can no longer reach the web ui
Steps to reproduce: - I generated a wildcard certificate using certbot with the command certbot certonly --manual -d *.domain.com -d domain.com --agree-tos --manual-public-ip-logging-ok --preferred-challenges dns-01 --server https://acme-v02.api.letsencrypt.org/directory --register-unsafely-without-email --rsa-key-size 4096 - I put the certificate in the directory /etc/coder.d and gave file permission to the coder user - in the coder.env file I enabled the TLS certificate:
CODER_ACCESS_URL=https://coder.domain.com
CODER_WILDCARD_ACCESS_URL=*.domain.com

CODER_ADDRESS=127.0.0.1:3000
CODER_PG_CONNECTION_URL=
CODER_TLS_CERT_FILE=/etc/coder.d/fullchain.pem
CODER_TLS_ENABLE=TRUE
CODER_TLS_KEY_FILE=/etc/coder.d/privkey.pem
CODER_ACCESS_URL=https://coder.domain.com
CODER_WILDCARD_ACCESS_URL=*.domain.com

CODER_ADDRESS=127.0.0.1:3000
CODER_PG_CONNECTION_URL=
CODER_TLS_CERT_FILE=/etc/coder.d/fullchain.pem
CODER_TLS_ENABLE=TRUE
CODER_TLS_KEY_FILE=/etc/coder.d/privkey.pem
- I restart the coder service using systemctl restart coder - The process starts with no errors: service coder status:
Jan 11 09:39:41 XXX systemd[1]: Starting "Coder - Self-hosted developer workspaces on your infra"...
Jan 11 09:39:41 XXX coder[243669]: WARN: --address and -a are deprecated, please use --http-address and --tls>
Jan 11 09:39:41 XXX coder[243669]: Using built-in PostgreSQL (/home/coder/.config/coderv2/postgres)
Jan 11 09:39:41 XXX coder[243669]: Started TLS/HTTPS listener at https://127.0.0.1:3000
Jan 11 09:39:41 XXX coder[243669]: View the Web UI: https://coder.domain.com
Jan 11 09:39:43 XXX coder[243669]: 2023-01-11 08:39:43.874 [INFO] (coderd.update_checker) <./co>
Jan 11 09:39:43 XXX coder[243669]: ==> Logs will stream in below (press ctrl+c to gracefully exit):
Jan 11 09:39:43 XXX systemd[1]: Started "Coder - Self-hosted developer workspaces on your infra".
Jan 11 09:39:41 XXX systemd[1]: Starting "Coder - Self-hosted developer workspaces on your infra"...
Jan 11 09:39:41 XXX coder[243669]: WARN: --address and -a are deprecated, please use --http-address and --tls>
Jan 11 09:39:41 XXX coder[243669]: Using built-in PostgreSQL (/home/coder/.config/coderv2/postgres)
Jan 11 09:39:41 XXX coder[243669]: Started TLS/HTTPS listener at https://127.0.0.1:3000
Jan 11 09:39:41 XXX coder[243669]: View the Web UI: https://coder.domain.com
Jan 11 09:39:43 XXX coder[243669]: 2023-01-11 08:39:43.874 [INFO] (coderd.update_checker) <./co>
Jan 11 09:39:43 XXX coder[243669]: ==> Logs will stream in below (press ctrl+c to gracefully exit):
Jan 11 09:39:43 XXX systemd[1]: Started "Coder - Self-hosted developer workspaces on your infra".
12 replies