This commit is contained in:
@@ -48,16 +48,16 @@ jobs:
|
|||||||
V2RAY_JSON: ${{ secrets.V2RAY_JSON }}
|
V2RAY_JSON: ${{ secrets.V2RAY_JSON }}
|
||||||
run: |
|
run: |
|
||||||
set -euo pipefail
|
set -euo pipefail
|
||||||
echo "$V2RAY_JSON" > "${GITHUB_WORKSPACE}/v2ray-client.json"
|
mkdir -p "${GITHUB_WORKSPACE}/v2ray"
|
||||||
jq . "${GITHUB_WORKSPACE}/v2ray-client.json" >/dev/null # 可选,校验 JSON
|
printf '%s' "$V2RAY_JSON" > "${GITHUB_WORKSPACE}/v2ray/config.json"
|
||||||
ls -l "${GITHUB_WORKSPACE}/v2ray-client.json"
|
jq . "${GITHUB_WORKSPACE}/v2ray/config.json" >/dev/null
|
||||||
|
|
||||||
- name: Start v2ray-client
|
- name: Start v2ray-client
|
||||||
run: |
|
run: |
|
||||||
docker rm -f v2ray-client >/dev/null 2>&1 || true
|
docker rm -f v2ray-client >/dev/null 2>&1 || true
|
||||||
docker run -d --name v2ray-client \
|
docker run -d --name v2ray-client \
|
||||||
--network host \
|
--network host \
|
||||||
-v ${{ github.workspace }}/v2ray-client.json:/etc/v2ray/config.json:ro \
|
-v ${{ github.workspace }}/v2ray:/etc/v2ray:ro \
|
||||||
v2fly/v2fly-core:latest \
|
v2fly/v2fly-core:latest \
|
||||||
run -c /etc/v2ray/config.json
|
run -c /etc/v2ray/config.json
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user