logo
0
0
WeChat Login

Lazy Clash

中文 English

Lazy Clash is a one-click deployment solution for Clash based on Docker Compose. It can help you quickly set up a Clash proxy service with automatically updated subscriptions. —— by ChatGPT

Personal usage scenarios:

  • Quick and painless deployment on router/NAS devices
  • Quick deployment on servers for temporary use, and can be deleted after use.

Features

  • Automatic update Clash subscription (based on Clash proxy-providers)
  • Unified proxy service based on subconverter format and automatic grouping.
  • On-line deployment with Docker Compose
  • Embedded YACD web control panel

Usage

  1. Clone this repo
git clone https://cnb.cool/kangaroohy/open-source/clash-with-ui.git
  1. Set your clash subscription url in .env file or mount your config file to /root/.config/clash/config.yaml
cd clash-with-ui cp .env.example .env # Set RAW_SUB_URL="your clash subscription url" in .env # (Optional) Set API_SECRET="your api secret" in .env

or

... volumes: - /path/to/your/config.yaml:/root/.config/clash/config.yaml ...
  1. Run docker-compose

just need keep subconverter directory and .env config file and docker-compose.yaml

docker compose up -d

If only local access proxy is needed, simply modify the YAML to make it accessible from 127.0.0.1

services: subconverter: image: docker.cnb.cool/kangaroohy/open-source/clash-with-ui/subconverter:latest deploy: resources: limits: memory: 128MB hostname: subconverter container_name: subconverter volumes: - ./subconverter/all_base.tpl:/base/base/all_base.tpl - ./subconverter/pref.toml:/base/pref.toml ports: - "127.0.0.1:25500:25500" clash-with-ui: image: docker.cnb.cool/kangaroohy/open-source/clash-with-ui:latest deploy: resources: limits: memory: 256MB container_name: clash-with-ui depends_on: - subconverter env_file: - .env ports: - "127.0.0.1:$ALL_PROXY_PORT:7890" - "127.0.0.1:$CONTROL_PANEL_PORT:9090"
  1. (Optional) Managment

View control panel: http://[server-ip]:9090/ui?hostname=[server-ip]

  1. (Optional) Export proxy
export https_proxy=http://[server-ip]:7890 export http_proxy=http://[server-ip]:7890 export all_proxy=socks5://[server-ip]:7890

Dependencies

FAQ

  • Why emmbedded web control panel?

    In many usage scenarios, there are no conditions to use a public control panel (such as yacd.haishan.me) to manage Clash.If conditions permit, you can still use your own management tool.

  • What should I do if I fail to build the project because I can't access Dockerhub / Github on the server?

    This project in itself exists for engineering purposes, and as a project contributor, I cannot provide dependencies that can be used in various complex internal and external network environments. I suggest that you fork this project and modify the Dockerfile and docker-compose yourself, pointing the dependencies to an accessible image source.

About

Clash代理软件,整合Yacd UI,结合subconverter可以将订阅地址转为config.yaml配置文件

Language
TOML38.4%
Markdown26.9%
Shell6.3%
Dockerfile1.8%
Others26.6%