Easy Xray + xtls-vision + reality in Docker
Go to file
quackerd 602f0a3449
All checks were successful
continuous-integration/drone/push Build is passing
per-user download directory
2022-12-05 08:46:24 +01:00
opt per-user download directory 2022-12-05 08:46:24 +01:00
.drone.yml clean new images 2022-12-02 13:52:11 +01:00
.env per-user download directory 2022-12-05 08:46:24 +01:00
.gitignore Initial commit 2020-05-04 09:13:58 +00:00
docker-compose.yml change restart to unless-stopped 2022-12-02 14:40:39 +01:00
Dockerfile per-user download directory 2022-12-05 08:46:24 +01:00
LICENSE Add license 2022-12-02 13:37:33 +00:00
README.md per-user download directory 2022-12-05 08:46:24 +01:00

Build Status

Xray + VLESS + XTLS + Nginx fallback in Docker!

What is d2ray?

d2ray is a single Docker container that provides easy and braindead configuration for Xray + XTLS + Nginx fallback. d2ray also offers currently hardcoded setup instructions and Xray binary packages for various OSes and architectures.

Features

  • Easy 5-minutes setup.
  • Automatic generation and renewal of Let's Encrypt SSL certificates.
  • Packaged Xray binary on the fallback website.
  • Per-user setup instructions for various architectures.

How to use?

  1. Download the docker-compose.yml from this repo.
  2. Create a .env file in the same directory and configure the instance to your liking.
    • See .env in the current repo.
    • PORT: the port to run Xray on.
    • FQDN: the domain name of your server, used to generate SSL certificates.
    • USERS: comma separated list of USERCONF allowed access to both Xray and resource downloads. Each USERCONF is of format userid@flow. userid is used as the credential for Xray. If flow is not specified it defaults to xtls-rprx-direct. For example, setting USERS to user1@xtls-rprx-direct,user2 means two users with userid user1 and user2 and both with flow xtls-rprx-direct.
    • LOGDIR: the directory to store logs, currently required.
  3. docker compose up -d
  4. You can access the Xray service using an Xray client. You can access the per-user resource downloads by accessing https://your-domain:your-port, entering the userid in the textbox at the bottom of the page and clicking the Download button next to it.

How to update?

  • docker compose down
  • docker compose pull
  • docker compose up -d

Notes

  1. Port 80 must be available on the host as it is required to obtain SSL certificates.
  2. Note the docker compose instead of docker-compose commands. d2ray is only tested with the newer docker-compose-plugin (install with your distribution's package manager) as opposed to legacy docker-compose.