feat: xray support

This commit is contained in:
zhom
2026-07-31 01:04:58 +04:00
parent 064bf297dd
commit 0a7d7803f2
112 changed files with 10291 additions and 772 deletions
+6 -6
View File
@@ -72,7 +72,7 @@ jobs:
with:
repository: ${{ vars.TAURI_WEBDRIVER_REPOSITORY }}
token: ${{ secrets.TAURI_WEBDRIVER_TOKEN || github.token }}
path: tauri-cross-platform-webdriver
path: tauri-wd
persist-credentials: false
- name: Install pnpm
@@ -98,7 +98,7 @@ jobs:
workspaces: |
donutbrowser/src-tauri -> target
donutbrowser/e2e/app -> target
tauri-cross-platform-webdriver -> target
tauri-wd -> target
- name: Install Tauri dependencies
if: runner.os == 'Linux'
@@ -147,7 +147,7 @@ jobs:
with:
repository: ${{ vars.TAURI_WEBDRIVER_REPOSITORY }}
token: ${{ secrets.TAURI_WEBDRIVER_TOKEN || github.token }}
path: tauri-cross-platform-webdriver
path: tauri-wd
persist-credentials: false
- name: Install pnpm
@@ -173,7 +173,7 @@ jobs:
workspaces: |
donutbrowser/src-tauri -> target
donutbrowser/e2e/app -> target
tauri-cross-platform-webdriver -> target
tauri-wd -> target
- name: Install app dependencies
working-directory: donutbrowser
@@ -214,7 +214,7 @@ jobs:
with:
repository: ${{ vars.TAURI_WEBDRIVER_REPOSITORY }}
token: ${{ secrets.TAURI_WEBDRIVER_TOKEN || github.token }}
path: tauri-cross-platform-webdriver
path: tauri-wd
persist-credentials: false
- name: Install pnpm
@@ -240,7 +240,7 @@ jobs:
workspaces: |
donutbrowser/src-tauri -> target
donutbrowser/e2e/app -> target
tauri-cross-platform-webdriver -> target
tauri-wd -> target
- name: Install Tauri dependencies
run: |
+5 -2
View File
@@ -67,13 +67,13 @@ jobs:
if: matrix.os == 'ubuntu-22.04'
run: |
sudo apt-get update
sudo apt install libwebkit2gtk-4.1-dev build-essential curl wget file libxdo-dev libssl-dev libayatana-appindicator3-dev librsvg2-dev openvpn
sudo apt install libwebkit2gtk-4.1-dev build-essential curl wget file libxdo-dev libssl-dev libayatana-appindicator3-dev librsvg2-dev openvpn unzip
- name: Install frontend dependencies
run: pnpm install --frozen-lockfile
- name: Build frontend
run: pnpm next build
run: pnpm build
- name: Get host target
id: host_target
@@ -101,6 +101,9 @@ jobs:
chmod +x src-tauri/binaries/donut-proxy-${HOST_TARGET}
fi
- name: Download verified Xray-core sidecar
run: node src-tauri/download-xray.mjs --target ${{ steps.host_target.outputs.target }}
- name: Run rustfmt check
run: cargo fmt --all -- --check
working-directory: src-tauri
+8 -2
View File
@@ -124,7 +124,7 @@ jobs:
if: matrix.platform == 'ubuntu-22.04' || matrix.platform == 'ubuntu-22.04-arm'
run: |
sudo apt-get update
sudo apt-get install -y libwebkit2gtk-4.1-dev libgtk-3-dev libayatana-appindicator3-dev librsvg2-dev libxdo-dev pkg-config xdg-utils
sudo apt-get install -y libwebkit2gtk-4.1-dev libgtk-3-dev libayatana-appindicator3-dev librsvg2-dev libxdo-dev pkg-config unzip xdg-utils
- name: Rust cache
uses: swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 #v2.9.1
@@ -139,7 +139,7 @@ jobs:
# from secrets explicitly — they are NOT inherited from the job env.
env:
NEXT_PUBLIC_TURNSTILE: ${{ secrets.NEXT_PUBLIC_TURNSTILE }}
run: pnpm exec next build
run: pnpm build
- name: Verify frontend dist exists
shell: bash
@@ -172,6 +172,9 @@ jobs:
chmod +x src-tauri/binaries/donut-proxy-${{ matrix.target }}
fi
- name: Download verified Xray-core sidecar
run: node src-tauri/download-xray.mjs --target ${{ matrix.target }}
- name: Import Apple certificate
if: matrix.platform == 'macos-latest'
env:
@@ -245,6 +248,9 @@ jobs:
# Copy sidecar binaries
cp "src-tauri/target/${{ matrix.target }}/release/donut-proxy.exe" "$PORTABLE_DIR/"
cp "src-tauri/binaries/xray-${{ matrix.target }}.exe" "$PORTABLE_DIR/xray.exe"
mkdir -p "$PORTABLE_DIR/licenses"
cp "src-tauri/binaries/xray-LICENSE.txt" "$PORTABLE_DIR/licenses/Xray-core-LICENSE.txt"
# The daemon is currently disabled (no Cargo bin target), so it isn't
# built. Copy it only if a build produced it, so the absent binary
# doesn't fail the job.
+8 -2
View File
@@ -131,7 +131,7 @@ jobs:
if: matrix.platform == 'ubuntu-22.04' || matrix.platform == 'ubuntu-22.04-arm'
run: |
sudo apt-get update
sudo apt-get install -y libwebkit2gtk-4.1-dev libgtk-3-dev libayatana-appindicator3-dev librsvg2-dev libxdo-dev pkg-config xdg-utils
sudo apt-get install -y libwebkit2gtk-4.1-dev libgtk-3-dev libayatana-appindicator3-dev librsvg2-dev libxdo-dev pkg-config unzip xdg-utils
- name: Rust cache
uses: swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 #v2.9.1
@@ -146,7 +146,7 @@ jobs:
# from secrets explicitly — they are NOT inherited from the job env.
env:
NEXT_PUBLIC_TURNSTILE: ${{ secrets.NEXT_PUBLIC_TURNSTILE }}
run: pnpm exec next build
run: pnpm build
- name: Verify frontend dist exists
shell: bash
@@ -193,6 +193,9 @@ jobs:
chmod +x src-tauri/binaries/donut-proxy-${{ matrix.target }}
fi
- name: Download verified Xray-core sidecar
run: node src-tauri/download-xray.mjs --target ${{ matrix.target }}
- name: Import Apple certificate
if: matrix.platform == 'macos-latest'
env:
@@ -259,6 +262,9 @@ jobs:
cp "src-tauri/target/${{ matrix.target }}/release/donutbrowser.exe" "$PORTABLE_DIR/Donut.exe"
cp "src-tauri/target/${{ matrix.target }}/release/donut-proxy.exe" "$PORTABLE_DIR/"
cp "src-tauri/binaries/xray-${{ matrix.target }}.exe" "$PORTABLE_DIR/xray.exe"
mkdir -p "$PORTABLE_DIR/licenses"
cp "src-tauri/binaries/xray-LICENSE.txt" "$PORTABLE_DIR/licenses/Xray-core-LICENSE.txt"
# The daemon is currently disabled (no Cargo bin target), so it isn't
# built. Copy it only if a build produced it, so the absent binary
# doesn't fail the job.