Sign inSign up

jearton1024/shadowsocks-libev

By jearton1024

•Updated over 1 year ago

Support ss-server, ss-manager, ss-local, v2ray-plugin. Based on Alpine.

Image
2

1.1K

jearton1024/shadowsocks-libev repository overview

⁠Quick start

  1. Configure network parameters on Linux system(Not required for other OS)
echo 'net.ipv4.tcp_fastopen=3' >> /etc/sysctl.conf
sysctl -p
  1. Run ss-server
docker run --name ss-server -p 8086:8086 -e SERVER_PASSWORD=youpass -d jearton1024/shadowsocks-libev

⁠Best Practices

You should always use a tsl certificate in nginx, instead of in v2ray-plugin's options.

  • Single instance: ss-server + v2ray-plugin + nginx⁠ + tsl + websocket reverse proxy
  • Multiple instances: ss-manager + v2ray-plugin + ssmgr⁠ + nginx⁠ + tsl + websocket reverse proxy

⁠Introspection

⁠The environment variables
  • RUN_MODE, default value is server. Available options are: server, manager
  • CONFIG_FILE, default value is /etc/shadowsocks-libev/config.json
  • SERVER_PASSWORD, default value is hostname in the container. Recommend overwriting it.
  • SERVER_PORT, default value is 8086.
  • MANAGER_ADDRESS, default value is 0.0.0.0:6001.
  • LOCAL_CONFIG_FILE, default value is /etc/shadowsocks-libev/local/config.json
⁠Exposed ports
  • 8086, which is the default port of the ss-server.
  • 6001/udp, which is the default port of the ss-manager.
⁠Versions
image tagshadowsocks-libevv2ray-plugin
latest3.3.5v1.3.1

⁠Default config file

Following is the default config file content, you can override it by using host volume to mount custom config path.

{
    "server": "0.0.0.0",
    "timeout": 60,
    "method": "aes-256-gcm",
    "nameserver": "8.8.8.8,8.8.4.4,2001:4860:4860::8888,2001:4860:4860::8844",
    "fast_open": true,
    "no_delay": true,
    "reuse_port": true,
    "mode": "tcp_and_udp",
    "plugin": "v2ray-plugin",
    "plugin_opts": "server;path=/v"
}

⁠Features

Main ProgramUsage
ss-serverMust use custom config file without plugin.
ss-server with v2ray-pluginCan use default or custom config file .
ss-managerMust define RUN_MODE=manager . Must use custom config file without plugin.
ss-manager with v2ray-pluginMust define RUN_MODE=manager . Can use default or custom config file.
ss-local with v2ray-pluginMust define RUN_MODE=local . Must mount LOCAL_CONFIG_FILE from host.

⁠Using custom config file

# run a container
docker run --name ss-server -d jearton1024/shadowsocks-libev

# copy the config file to you host's directory.
docker cp ss-server:/etc/shadowsocks-libev /etc/

# destory the container
docker stop ss-server && docker rm ss-server

# run a new container
docker run --name ss-server \
    --restart=always \
    -p 8086:8086
    -e SERVER_PASSWORD=youpass \
    -v /etc/shadowsocks-libev:/etc/shadowsocks-libev \
    -d jearton1024/shadowsocks-libev

⁠Run ss-manager with v2ray-plugin

# First you should copy the config file in container to you host's directory, and then run this: 
docker run --name ss-manager \
    --restart always \
    -e RUN_MODE=manager \
    -v /etc/shadowsocks-libev:/etc/shadowsocks-libev \
    -d jearton1024/shadowsocks-libev

⁠Run ss-local with v2ray-plugin

docker run --name ss-local \
    --network backend \
    --restart always \
    -e RUN_MODE=local \
    -v ~/docker/ss-local:/etc/shadowsocks-libev/local \
    -d jearton1024/shadowsocks-libev

⁠Contact me if any feedback

[email protected]⁠

Tag summary

Content type

Image

Digest

Size

12.7 MB

Last updated

almost 5 years ago

docker pull jearton1024/shadowsocks-libev