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

How to configure ssl if 3x-ui is used in docker container? #2166

Open
wedcanto opened this issue Mar 30, 2024 · 0 comments
Open

How to configure ssl if 3x-ui is used in docker container? #2166

wedcanto opened this issue Mar 30, 2024 · 0 comments

Comments

@wedcanto
Copy link

wedcanto commented Mar 30, 2024

I ran the commands

apt-get install certbot -y
certbot certonly --standalone --agree-tos --register-unsafely-without-email -d mydomain.com
certbot renew --dry-run

Successfully got the certificates, they are stored in the

 /etc/letsencrypt/live/mydomain.com/fullchain.pem
/etc/letsencrypt/live/mydomain.com/privkey.pem

I tried changing the docker-compose.yaml to this one:

version: "3"

services:
  3x-ui:
    image: ghcr.io/mhsanaei/3x-ui:latest
    container_name: 3x-ui
    hostname: yourhostname
    volumes:
      - /etc/letsencrypt/live/mydomain.com/fullchain.pem:/root/cert/fullchain.pem:ro
      - /etc/letsencrypt/live/mydomain.com/privkey.pem:/root/cert/privkey.pem:ro
      - ./db/:/etc/x-ui/
    environment:
      XRAY_VMESS_AEAD_FORCED: "false"
    tty: true
    network_mode: host
    restart: unless-stopped

But I still have error - SSL_ERROR_RX_RECORD_TOO_LONG

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

1 participant