doc: add info for customize building

This commit is contained in:
nadoo committed 2020-10-02 00:03:49 +08:00
1 parent edfca215c5
commit bc68535dcd
2 files changed
+27 -15

No files matched your search

+22 -10
View File
@@ -71,15 +71,9 @@ we can set up local listeners as proxy servers, and forward requests to internet
## Install
Binary Download:
Download:
- [https://github.com/nadoo/glider/releases](https://github.com/nadoo/glider/releases)
Build from source code (requires **Go 1.15+** ):
```bash
git clone https://github.com/nadoo/glider
cd glider && go build
```
ArchLinux:
```bash
sudo pacman -S glider
@@ -371,9 +365,7 @@ glider -config CONFIGPATH -listen :8080 -verbose
## Service
#### Scheme:
```service=SERVICE_NAME[,SERVICE_CONFIG]```
**Scheme:** ```service=SERVICE_NAME[,SERVICE_CONFIG]```
- dhcpd:
- service=dhcpd,INTERFACE,START_IP,END_IP
@@ -383,6 +375,26 @@ glider -config CONFIGPATH -listen :8080 -verbose
- systemd: [https://github.com/nadoo/glider/blob/master/systemd/](https://github.com/nadoo/glider/blob/master/systemd/)
## Customize Build
You can customize and build glider by yourself if you want a smaller binary.
1. Clone the source code:
```bash
git clone https://github.com/nadoo/glider
```
2. Customize features:
```open `feature.go` & `feature_linux.go`, comment out the packages you don't need```
```bash
// _ "github.com/nadoo/glider/proxy/kcp"
```
3. Build it(requires **Go 1.15+** )
```bash
cd glider && go build
```
## Links
- [ipset](https://github.com/nadoo/ipset): netlink ipset package for Go.