Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Connection problem between dokploy and components on LXC #65

Open
LeslieLeung opened this issue May 9, 2024 · 5 comments
Open

Connection problem between dokploy and components on LXC #65

LeslieLeung opened this issue May 9, 2024 · 5 comments

Comments

@LeslieLeung
Copy link

I am trying to install dokploy on a Proxmox VE LXC. The dokploy and all its components can start without any problem, but when I follow the link in the end of the installation, the page won't load and get a 500 Internal Error.

Upon checking the log of the dokploy container, clearly it can't talk to the redis and postgres. Here is the log:

 ⨯ Error: write CONNECT_TIMEOUT dokploy-postgres:5432
    at connectTimedOut (file:///app/node_modules/.pnpm/postgres@3.4.4/node_modules/postgres/src/connection.js:257:20)
    at Timeout.done [as _onTimeout] (file:///app/node_modules/.pnpm/postgres@3.4.4/node_modules/postgres/src/connection.js:1033:8)
    at listOnTimeout (node:internal/timers:571:11)
    at process.processTimers (node:internal/timers:512:7) {
  code: 'CONNECT_TIMEOUT',
  errno: 'CONNECT_TIMEOUT',
  address: 'dokploy-postgres',
  port: 5432
}
Error: connect ETIMEDOUT
    at Socket.<anonymous> (/app/node_modules/.pnpm/ioredis@5.3.2/node_modules/ioredis/built/Redis.js:170:41)
    at Object.onceWrapper (node:events:631:28)
    at Socket.emit (node:events:517:28)
    at Socket._onTimeout (node:net:598:8)
    at listOnTimeout (node:internal/timers:569:17)
    at process.processTimers (node:internal/timers:512:7) {
  errorno: 'ETIMEDOUT',
  code: 'ETIMEDOUT',
  syscall: 'connect'
}

I can confirm traefik, redis, postgres and the dokploy containers are up and running:

CONTAINER ID   IMAGE                    COMMAND                  CREATED          STATUS          PORTS                                                                                                                 NAMES
6572e6aa7b00   redis:7                  "docker-entrypoint.s…"   16 minutes ago   Up 16 minutes   6379/tcp                                                                                                              dokploy-redis.1.kjx49cyo7r0y3qxm5qxqkhy79
83ccc4c98f5c   traefik:v2.5             "/entrypoint.sh trae…"   16 minutes ago   Up 16 minutes   0.0.0.0:80->80/tcp, :::80->80/tcp, 0.0.0.0:443->443/tcp, :::443->443/tcp, 0.0.0.0:8080->8080/tcp, :::8080->8080/tcp   dokploy-traefik.1.7v5t1a7m88udld82mpwdr1d97
f1c94cf7c034   postgres:16              "docker-entrypoint.s…"   16 minutes ago   Up 16 minutes   5432/tcp                                                                                                              dokploy-postgres.1.uajqlmpkmikos2xx670q6iwrh
233a0b9e1746   dokploy/dokploy:latest   "docker-entrypoint.s…"   17 minutes ago   Up 17 minutes   0.0.0.0:3000->3000/tcp, :::3000->3000/tcp                                                                             dokploy.1.pk9dz8qwonpmc6wi0nq8be711

Here is my installation process:

  • Create a clean Ubuntu 22.04 LXC with bash -c "$(wget -qLO - https://github.com/tteck/Proxmox/raw/main/ct/ubuntu.sh)"
  • Run the script curl -sSL https://dokploy.com/install.sh | sh
@Siumauricio
Copy link
Contributor

This is a proxmox problem, not dokploy, many people have tried to use it but you have to make certain configurations regarding routes and ips, I can't give you an exact solution since I have never used proxmox, on discord several people have solved this problem

If you can tell me where I can rent a server with Proxmox to try it, I would be happy to make a guide.

@LeslieLeung
Copy link
Author

I've joined the discord server and read some of the chats before about Proxmox. So it appears that dokploy on a VM works but not LXC, probably docker network problem. I believe there is a solution to this. LXC is better than VM because it's lighter.

If you can tell me where I can rent a server with Proxmox to try it, I would be happy to make a guide.

About this, I found some websites on the Proxmox Hosting Partners, see here. But you can run a Proxmox server with really cheap hardware(it's basically Debian with a management software for qemu). I think deploying your own Proxmox server would be a better choice.

A guide to run dokploy on Proxmox VE would be great because a) dokploy is really a great work and very suitable for self hosting, b) Proxmox VE is a popular choice for homeservers.

@Mr1Blaze
Copy link
Contributor

Which ubuntu 20.04 are you use? Because in my case it's work very well. How was created and configured CT on proxmox?

@LeslieLeung
Copy link
Author

It's Ubuntu 22.04 and privileged.

Distributor ID: Ubuntu
Description:    Ubuntu 22.04.4 LTS
Release:        22.04
Codename:       jammy

Here is the /etc/pve/lxc/x.conf:

arch: amd64
cores: 2
features: nesting=1
hostname: ubuntu
memory: 4096
net0: name=eth0,bridge=vmbr0,gw=xxx,hwaddr=xxx,ip=xxx/24,type=veth
onboot: 1
ostype: ubuntu
rootfs: local-lvm:vm-101-disk-0,size=128G
swap: 512
tags: proxmox-helper-scripts
lxc.cgroup2.devices.allow: a
lxc.cap.drop: 
lxc.cgroup2.devices.allow: c 188:* rwm
lxc.cgroup2.devices.allow: c 189:* rwm
lxc.mount.entry: /dev/serial/by-id  dev/serial/by-id  none bind,optional,create=dir
lxc.mount.entry: /dev/ttyUSB0       dev/ttyUSB0       none bind,optional,create=file
lxc.mount.entry: /dev/ttyUSB1       dev/ttyUSB1       none bind,optional,create=file
lxc.mount.entry: /dev/ttyACM0       dev/ttyACM0       none bind,optional,create=file
lxc.mount.entry: /dev/ttyACM1       dev/ttyACM1       none bind,optional,create=file

@Mr1Blaze
Copy link
Contributor

Looks good. But I recommend to deploy on Virtual Machine in Proxmox VE. On LXC will be so slower

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants