以服務執行
本指南適用於使用 systemd 的系統,說明如何啟動 dae 服務並設定開機自動啟動。
必要條件
選用的 Geo 資料檔案
為了更方便地進行流量分流,dae 仰賴下列資料來源:geoip.dat 和 geosite.dat。
shell
sudo mkdir -p /usr/local/share/dae/
pushd /usr/local/share/dae/
sudo curl -L -o geoip.dat https://github.com/v2fly/geoip/releases/latest/download/geoip.dat
sudo curl -L -o geosite.dat https://github.com/v2fly/domain-list-community/releases/latest/download/dlc.dat
popdshell
mkdir -p /usr/local/share/dae/
pushd /usr/local/share/dae/
curl -L -o geoip.dat https://github.com/v2fly/geoip/releases/latest/download/geoip.dat
curl -L -o geosite.dat https://github.com/v2fly/domain-list-community/releases/latest/download/dlc.dat
popd設定檔
注意:建議將設定檔儲存在
/etc/dae下
下載範例設定檔:
shell
sudo mkdir -p /etc/dae
sudo curl -L -o /etc/dae/config.dae https://github.com/daeuniverse/dae/raw/main/example.dae
sudo chmod 600 /etc/dae/config.daeshell
mkdir -p /etc/dae
curl -L -o /etc/dae/config.dae https://github.com/daeuniverse/dae/raw/main/example.dae
chmod 600 /etc/dae/config.dae啟動服務前,編輯 /etc/dae/config.dae,設定網路介面、訂閱或節點。請參閱最小設定。
下載預先編譯的二進位檔
發行版本位於 https://github.com/daeuniverse/dae/releases
注意:如果你想體驗新功能,可以使用夜間(最新)建置。大多數時候,新提出的變更會包含在
PRs中,並會在建置(GitHub Action Workflow Build)中匯出為跨平台可執行二進位檔。請注意,新引入的功能有時存在錯誤,風險由你自行承擔。不過,我們仍強烈鼓勵你查看最新建置,因為這可能有助於我們進一步分析功能穩定性並相應地解決潛在錯誤。
夜間建置位於 https://github.com/daeuniverse/dae/actions/workflows/build-nightly.yml
shell
sudo chmod +x ./dae
sudo install -Dm755 dae /usr/bin/shell
chmod +x ./dae
install -Dm755 dae /usr/bin/檢查執行檔
shell
# helper
dae --help
# check version
dae version設定
shell
# download the sample systemd.service
sudo curl -L -o /etc/systemd/system/dae.service https://github.com/daeuniverse/dae/raw/main/install/dae.serviceshell
# download the sample systemd.service
curl -L -o /etc/systemd/system/dae.service https://github.com/daeuniverse/dae/raw/main/install/dae.service啟動並啟用服務
shell
sudo systemctl daemon-reload
sudo systemctl enable dae --now
sudo systemctl status daeshell
systemctl daemon-reload
systemctl enable dae --now
systemctl status dae檢查系統日誌
shell
sudo journalctl -xefu daeshell
journalctl -xefu dae來源:dae 上游文件 · AGPL-3.0 授權條款。
