mirror of
https://github.com/shadowsocks/shadowsocks-libev.git
synced 2026-10-28 03:33:42 +00:00
Merge pull request #1 from xiaoding/xiaoding-patch-freebsd
Update FreeBSD section in README.md
This commit is contained in:
@@ -59,6 +59,10 @@ sudo snap install shadowsocks-libev --edge
|
||||
- [Nix](#nix)
|
||||
- [Directly build and install on UNIX-like system](#linux)
|
||||
- [FreeBSD](#freebsd)
|
||||
+ [Install](#install)
|
||||
+ [Configuration](#configuration)
|
||||
+ [Run](#run)
|
||||
+ [Run as client](#run-as-client)
|
||||
- [OpenWRT](#openwrt)
|
||||
- [OS X](#os-x)
|
||||
- [Windows (MinGW)](#windows-mingw)
|
||||
@@ -294,27 +298,49 @@ sudo make install
|
||||
You may need to manually install missing softwares.
|
||||
|
||||
### FreeBSD
|
||||
#### Install
|
||||
Shadowsocks-libev is available in FreeBSD Ports Collection. You can install it in either way, `pkg` or `ports`.
|
||||
|
||||
**pkg (recommended)**
|
||||
|
||||
```bash
|
||||
pkg install shadowsocks-libev
|
||||
```
|
||||
|
||||
**ports**
|
||||
|
||||
```bash
|
||||
su
|
||||
cd /usr/ports/net/shadowsocks-libev
|
||||
make install
|
||||
```
|
||||
|
||||
Edit your config.json file. By default, it's located in /usr/local/etc/shadowsocks-libev.
|
||||
#### Configuration
|
||||
Edit your `config.json` file. By default, it's located in `/usr/local/etc/shadowsocks-libev`.
|
||||
|
||||
To enable shadowsocks-libev, add the following rc variable to your /etc/rc.conf file:
|
||||
To enable shadowsocks-libev, add the following rc variable to your `/etc/rc.conf` file:
|
||||
|
||||
```
|
||||
shadowsocks_libev_enable="YES"
|
||||
```
|
||||
|
||||
#### Run
|
||||
|
||||
Start the Shadowsocks server:
|
||||
|
||||
```bash
|
||||
service shadowsocks_libev start
|
||||
```
|
||||
|
||||
#### Run as client
|
||||
By default, shadowsocks-libev is running as a server in FreeBSD. If you would like to start shadowsocks-libev in client mode, you can modify the rc script (`/usr/local/etc/rc.d/shadowsocks_libev`) manually.
|
||||
|
||||
```
|
||||
# modify the following line from "ss-server" to "ss-local"
|
||||
command="/usr/local/bin/ss-local"
|
||||
```
|
||||
|
||||
Note that is simply a workaround, each time you upgrade the port your changes will be overwritten by the new version.
|
||||
|
||||
### OpenWRT
|
||||
|
||||
The OpenWRT project is maintained here:
|
||||
|
||||
Reference in New Issue
Block a user