Easy Xray + xtls-vision + reality in Docker
Go to file
2021-01-19 02:10:52 +00:00
.gitignore Initial commit 2020-05-04 09:13:58 +00:00
client_conf.in new format 2021-01-16 17:53:44 -05:00
client_obj.in new format 2021-01-16 17:53:44 -05:00
config.yml new format 2021-01-16 18:13:11 -05:00
configure.py fix nginx 2021-01-16 18:58:03 -05:00
docker-compose.in fix nginx 2021-01-16 18:57:15 -05:00
LICENSE new format 2021-01-16 17:53:44 -05:00
nginx.in new format 2021-01-16 17:53:44 -05:00
README.md Update 'README.md' 2021-01-19 02:10:52 +00:00
server.in new format 2021-01-16 17:53:44 -05:00
watchtower.in new format 2021-01-16 17:53:44 -05:00

d2ray

Clean, dockerized v2ray(Websocket + TLS) + Nginx + Let's Encrypt with official and well-maintained docker containers. No BS private containers.

Supports:

  • v2ray with websocket + TLS protocol using the teddysun/v2ray.
  • Nginx frontend and auto-renewing Let's Encrypt certificate using the popular linuxserver/swag.
  • watchtower for automatic docker image updates (can be disabled) from containrrr/watchtower
  • Easy multiuser configuration and user conf file generation.

Usage:

Required packages

  • python3: On CentOS 7: yum install python3
  • docker-ce
  • docker-compose
  • jinja2: A popular python template processor. Install with pip3 install jinja2.
  • pyyaml: Python YAML parser. Install with pip3 install pyyaml.

Building

  • Clone this repo.
  • Modify config.yml to your liking. Please see the comments in the file for documentation.
  • Run configure.py with python 3.
  • Generated files are located in the build directory. Run docker-compose up -d within that directory to start the stack.
  • To start over or to update the existing configuration. Simply change config.yml, rerun configure.py and restart the stack.

Client connections

Client conf files are generated in build/clients/[name]_[uuid]/config.json. Clients simply need to download the most recent v2ray release and replace config.json with the ones generated. The config file by default directly connects to CN mainland websites and proxies foreign websites. The same goes for DNS lookups.

You can customize the template file client_conf.in to generate custom client conf files.

Troubleshooting

  • Make sure your subdomain.domain.tld points to the server.
  • Use docker logs v2ray_nginx to check for nginx init errors. Detailed nginx logs and be found in nginx/logs/nginx
  • Use docker logs v2ray_v2ray to check for v2ray init errors.
  • Use docker logs v2ray_watchtower to check for watchtower errors.