From 5ae3c098649933d3253194c52cf6245394e53cbf Mon Sep 17 00:00:00 2001 From: snltty <1069410172@qq.com> Date: Tue, 5 Nov 2024 16:01:11 +0800 Subject: [PATCH] sync --- .github/workflows/docker.yml | 8 +-- .github/workflows/dotnet.yml | 30 ++++---- .github/workflows/nuget.yml | 6 +- linker.libs/linker.libs.csproj | 6 +- linker.tun/linker.tun.csproj | 6 +- linker.tunnel/linker.tunnel.csproj | 6 +- linker.web/src/apis/relay.js | 3 + .../views/full/devices/ConnectionsEdit.vue | 68 +++++++++++++++++-- .../src/views/full/server/RelayServers.vue | 3 +- linker/linker.csproj | 14 ++-- .../relay/client/RelayApiController.cs | 20 +++++- linker/plugins/relay/client/RelayTransfer.cs | 6 +- .../client/transport/TransportSelfHost.cs | 19 ++++-- linker/plugins/relay/config/Config.cs | 9 +++ linker/plugins/relay/server/RelayResolver.cs | 7 +- .../relay/server/RelayServerMasterTransfer.cs | 2 + .../relay/server/RelayServerNodeTransfer.cs | 2 +- publish-docker.sh | 6 +- version.txt | 12 ++-- 19 files changed, 162 insertions(+), 71 deletions(-) diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index ea5fdc82..28467ce1 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -57,9 +57,9 @@ jobs: docker tag snltty/linker-musl-x64:latest snltty/linker-musl:amd64 && \ docker push snltty/linker-musl:amd64 && \ docker manifest create snltty/linker-musl:latest snltty/linker-musl:amd64 snltty/linker-musl:arm64 snltty/linker-musl:arm && \ - docker manifest create snltty/linker-musl:v1.5.1 snltty/linker-musl:amd64 snltty/linker-musl:arm64 snltty/linker-musl:arm && \ + docker manifest create snltty/linker-musl:v1.5.2 snltty/linker-musl:amd64 snltty/linker-musl:arm64 snltty/linker-musl:arm && \ docker manifest push snltty/linker-musl:latest && \ - docker manifest push snltty/linker-musl:v1.5.1 && \ + docker manifest push snltty/linker-musl:v1.5.2 && \ docker pull --platform linux/arm/v7 snltty/linker-debian-arm:latest && \ docker tag snltty/linker-debian-arm:latest snltty/linker-debian:arm && \ docker push snltty/linker-debian:arm && \ @@ -70,6 +70,6 @@ jobs: docker tag snltty/linker-debian-x64:latest snltty/linker-debian:amd64 && \ docker push snltty/linker-debian:amd64 && \ docker manifest create snltty/linker-debian:latest snltty/linker-debian:amd64 snltty/linker-debian:arm64 snltty/linker-debian:arm && \ - docker manifest create snltty/linker-debian:v1.5.1 snltty/linker-debian:amd64 snltty/linker-debian:arm64 snltty/linker-debian:arm && \ + docker manifest create snltty/linker-debian:v1.5.2 snltty/linker-debian:amd64 snltty/linker-debian:arm64 snltty/linker-debian:arm && \ docker manifest push snltty/linker-debian:latest && \ - docker manifest push snltty/linker-debian:v1.5.1 \ No newline at end of file + docker manifest push snltty/linker-debian:v1.5.2 \ No newline at end of file diff --git a/.github/workflows/dotnet.yml b/.github/workflows/dotnet.yml index 06e8629a..30745cac 100644 --- a/.github/workflows/dotnet.yml +++ b/.github/workflows/dotnet.yml @@ -33,11 +33,11 @@ jobs: env: GITHUB_TOKEN: ${{ secrets.ACTIONS_TOKEN }} with: - tag_name: v1.5.1 - release_name: v1.5.1.${{ steps.date.outputs.today }} + tag_name: v1.5.2 + release_name: v1.5.2.${{ steps.date.outputs.today }} draft: false prerelease: false - body: "1. 优化点对网和网对网的局域网IP,包括禁用IP,和冲突检测\r\n2. 一些UI优化\r\n3. 新增socks5代理\r\n4. 优化端口转发和内网穿透配置\r\n5. 优化网卡的一些东西\r\n6. 统一的去中心数据同步,减少bug" + body: "1. 多中继节点服务器\r\n6. 测试中,不要更新,不要更新,不要更新" - name: upload-win-x86-oss id: upload-win-x86-oss uses: tvrcgo/oss-action@v0.1.1 @@ -47,7 +47,7 @@ jobs: key-secret: ${{ secrets.ALIYUN_OSS_SECRET }} bucket: ide-qbcode asset-path: ./public/publish-zip/linker-win-x86.zip - target-path: /downloads/linker/v1.5.1/linker-win-x86.zip + target-path: /downloads/linker/v1.5.2/linker-win-x86.zip - name: upload-win-x86 id: upload-win-x86 uses: actions/upload-release-asset@master @@ -67,7 +67,7 @@ jobs: key-secret: ${{ secrets.ALIYUN_OSS_SECRET }} bucket: ide-qbcode asset-path: ./public/publish-zip/linker-win-x64.zip - target-path: /downloads/linker/v1.5.1/linker-win-x64.zip + target-path: /downloads/linker/v1.5.2/linker-win-x64.zip - name: upload-win-x64 id: upload-win-x64 uses: actions/upload-release-asset@master @@ -87,7 +87,7 @@ jobs: key-secret: ${{ secrets.ALIYUN_OSS_SECRET }} bucket: ide-qbcode asset-path: ./public/publish-zip/linker-win-arm64.zip - target-path: /downloads/linker/v1.5.1/linker-win-arm64.zip + target-path: /downloads/linker/v1.5.2/linker-win-arm64.zip - name: upload-win-arm64 id: upload-win-arm64 uses: actions/upload-release-asset@master @@ -107,7 +107,7 @@ jobs: key-secret: ${{ secrets.ALIYUN_OSS_SECRET }} bucket: ide-qbcode asset-path: ./public/publish-zip/linker-linux-x64.zip - target-path: /downloads/linker/v1.5.1/linker-linux-x64.zip + target-path: /downloads/linker/v1.5.2/linker-linux-x64.zip - name: upload-linux-x64 id: upload-linux-x64 uses: actions/upload-release-asset@master @@ -127,7 +127,7 @@ jobs: key-secret: ${{ secrets.ALIYUN_OSS_SECRET }} bucket: ide-qbcode asset-path: ./public/publish-zip/linker-linux-arm.zip - target-path: /downloads/linker/v1.5.1/linker-linux-arm.zip + target-path: /downloads/linker/v1.5.2/linker-linux-arm.zip - name: upload-linux-arm id: upload-linux-arm uses: actions/upload-release-asset@master @@ -147,7 +147,7 @@ jobs: key-secret: ${{ secrets.ALIYUN_OSS_SECRET }} bucket: ide-qbcode asset-path: ./public/publish-zip/linker-linux-arm64.zip - target-path: /downloads/linker/v1.5.1/linker-linux-arm64.zip + target-path: /downloads/linker/v1.5.2/linker-linux-arm64.zip - name: upload-linux-arm64 id: upload-linux-arm64 uses: actions/upload-release-asset@master @@ -167,7 +167,7 @@ jobs: key-secret: ${{ secrets.ALIYUN_OSS_SECRET }} bucket: ide-qbcode asset-path: ./public/publish-zip/linker-linux-musl-x64.zip - target-path: /downloads/linker/v1.5.1/linker-linux-musl-x64.zip + target-path: /downloads/linker/v1.5.2/linker-linux-musl-x64.zip - name: upload-linux-musl-x64 id: upload-linux-musl-x64 uses: actions/upload-release-asset@master @@ -187,7 +187,7 @@ jobs: key-secret: ${{ secrets.ALIYUN_OSS_SECRET }} bucket: ide-qbcode asset-path: ./public/publish-zip/linker-linux-musl-arm.zip - target-path: /downloads/linker/v1.5.1/linker-linux-musl-arm.zip + target-path: /downloads/linker/v1.5.2/linker-linux-musl-arm.zip - name: upload-linux-musl-arm id: upload-linux-musl-arm uses: actions/upload-release-asset@master @@ -207,7 +207,7 @@ jobs: key-secret: ${{ secrets.ALIYUN_OSS_SECRET }} bucket: ide-qbcode asset-path: ./public/publish-zip/linker-linux-musl-arm64.zip - target-path: /downloads/linker/v1.5.1/linker-linux-musl-arm64.zip + target-path: /downloads/linker/v1.5.2/linker-linux-musl-arm64.zip - name: upload-linux-musl-arm64 id: upload-linux-musl-arm64 uses: actions/upload-release-asset@master @@ -227,7 +227,7 @@ jobs: key-secret: ${{ secrets.ALIYUN_OSS_SECRET }} bucket: ide-qbcode asset-path: ./public/publish-zip/linker-osx-x64.zip - target-path: /downloads/linker/v1.5.1/linker-osx-x64.zip + target-path: /downloads/linker/v1.5.2/linker-osx-x64.zip - name: upload-osx-x64 id: upload-osx-x64 uses: actions/upload-release-asset@master @@ -247,7 +247,7 @@ jobs: key-secret: ${{ secrets.ALIYUN_OSS_SECRET }} bucket: ide-qbcode asset-path: ./public/publish-zip/linker-osx-arm64.zip - target-path: /downloads/linker/v1.5.1/linker-osx-arm64.zip + target-path: /downloads/linker/v1.5.2/linker-osx-arm64.zip - name: upload-osx-arm64 id: upload-osx-arm64 uses: actions/upload-release-asset@master @@ -277,7 +277,7 @@ jobs: key-secret: ${{ secrets.ALIYUN_OSS_SECRET }} bucket: ide-qbcode asset-path: ./public/publish-zip/linker-windows-route.zip - target-path: /downloads/linker/v1.5.1/linker-windows-route.zip + target-path: /downloads/linker/v1.5.2/linker-windows-route.zip - name: upload-windows-route id: upload-windows-route uses: actions/upload-release-asset@master diff --git a/.github/workflows/nuget.yml b/.github/workflows/nuget.yml index 0f438ca1..4ecbd170 100644 --- a/.github/workflows/nuget.yml +++ b/.github/workflows/nuget.yml @@ -38,6 +38,6 @@ jobs: - name: Push run: | - nuget push ./linker.tunnel/bin/release/linker.tunnel.1.5.1.nupkg -Source https://api.nuget.org/v3/index.json -SkipDuplicate -ApiKey ${{ secrets.NUGET_KEY }} -NoSymbol - nuget push ./linker.libs/bin/release/linker.libs.1.5.1.nupkg -Source https://api.nuget.org/v3/index.json -SkipDuplicate -ApiKey ${{ secrets.NUGET_KEY }} -NoSymbol - nuget push ./linker.tun/bin/release/linker.tun.1.5.1.nupkg -Source https://api.nuget.org/v3/index.json -SkipDuplicate -ApiKey ${{ secrets.NUGET_KEY }} -NoSymbol + nuget push ./linker.tunnel/bin/release/linker.tunnel.1.5.2.nupkg -Source https://api.nuget.org/v3/index.json -SkipDuplicate -ApiKey ${{ secrets.NUGET_KEY }} -NoSymbol + nuget push ./linker.libs/bin/release/linker.libs.1.5.2.nupkg -Source https://api.nuget.org/v3/index.json -SkipDuplicate -ApiKey ${{ secrets.NUGET_KEY }} -NoSymbol + nuget push ./linker.tun/bin/release/linker.tun.1.5.2.nupkg -Source https://api.nuget.org/v3/index.json -SkipDuplicate -ApiKey ${{ secrets.NUGET_KEY }} -NoSymbol diff --git a/linker.libs/linker.libs.csproj b/linker.libs/linker.libs.csproj index cbae780d..4a85ceaf 100644 --- a/linker.libs/linker.libs.csproj +++ b/linker.libs/linker.libs.csproj @@ -14,9 +14,9 @@ snltty https://github.com/snltty/linker https://github.com/snltty/linker - 1.5.1 - 1.5.1 - 1.5.1 + 1.5.2 + 1.5.2 + 1.5.2 full diff --git a/linker.tun/linker.tun.csproj b/linker.tun/linker.tun.csproj index a5362db6..f6235f30 100644 --- a/linker.tun/linker.tun.csproj +++ b/linker.tun/linker.tun.csproj @@ -16,9 +16,9 @@ https://github.com/snltty/linker https://github.com/snltty/linker linker tun - 1.5.1 - 1.5.1 - 1.5.1 + 1.5.2 + 1.5.2 + 1.5.2 diff --git a/linker.tunnel/linker.tunnel.csproj b/linker.tunnel/linker.tunnel.csproj index 884260a9..895e6e7b 100644 --- a/linker.tunnel/linker.tunnel.csproj +++ b/linker.tunnel/linker.tunnel.csproj @@ -16,9 +16,9 @@ https://github.com/snltty/linker https://github.com/snltty/linker linker tunnel - 1.5.1 - 1.5.1 - 1.5.1 + 1.5.2 + 1.5.2 + 1.5.2 diff --git a/linker.web/src/apis/relay.js b/linker.web/src/apis/relay.js index ee5daed1..e5dc2d70 100644 --- a/linker.web/src/apis/relay.js +++ b/linker.web/src/apis/relay.js @@ -5,4 +5,7 @@ export const setRelayServers = (servers) => { } export const setRelaySubscribe = () => { return sendWebsocketMsg('relay/Subscribe'); +} +export const relayConnect = (data) => { + return sendWebsocketMsg('relay/Connect', data); } \ No newline at end of file diff --git a/linker.web/src/views/full/devices/ConnectionsEdit.vue b/linker.web/src/views/full/devices/ConnectionsEdit.vue index 9e876c7f..8b7cde13 100644 --- a/linker.web/src/views/full/devices/ConnectionsEdit.vue +++ b/linker.web/src/views/full/devices/ConnectionsEdit.vue @@ -1,5 +1,5 @@ - + @@ -39,9 +39,7 @@ - - - + {{ state.nodesDic[scope.row.NodeId] || '选择节点' }} @@ -60,6 +58,39 @@ + + + + + + + 无限制 + {{ scope.row.MaxBandwidth }}Mbps + + + + + {{ scope.row.ConnectionRatio*100 }}% + + + + + {{ scope.row.Delay }}ms + + + + + + + + + + 使用 + + + + +