diff --git a/.gitea/workflows/build_ubuntu.yaml b/.gitea/workflows/build_ubuntu.yaml index 43cc793..edfdee4 100644 --- a/.gitea/workflows/build_ubuntu.yaml +++ b/.gitea/workflows/build_ubuntu.yaml @@ -18,8 +18,11 @@ jobs: container: image: registry.cn-shenzhen.aliyuncs.com/amass_toolset/ubuntu_dev:24.04 steps: - - name: Check out repository code - uses: actions/checkout@v4 + - name: Clone repository + run: | + echo "git clone --depth 1 --branch=${GITHUB_REF##*/} ssh://git@frp-by1.wwvvww.cn:22022/${{ gitea.repository }}.git" + git clone --depth 1 --branch=${GITHUB_REF##*/} ssh://git@frp-by1.wwvvww.cn:22022/${{ gitea.repository }}.git . + git checkout ${GITHUB_SHA} - run: resources/build.sh build - run: resources/build.sh deploy - name: Notify diff --git a/.gitea/workflows/build_windows.yaml b/.gitea/workflows/build_windows.yaml index 07e174d..104c01e 100644 --- a/.gitea/workflows/build_windows.yaml +++ b/.gitea/workflows/build_windows.yaml @@ -7,12 +7,12 @@ jobs: steps: - name: Set up SSH run: | - if (-Not (Test-Path -Path $HOME\.ssh)) { - mkdir $HOME\.ssh + if (-Not (Test-Path -Path C:\Windows\system32\config\systemprofile\.ssh)) { + mkdir C:\Windows\system32\config\systemprofile\.ssh } - echo $env:SSH_PRIVATE_KEY | Out-File -FilePath $HOME\.ssh\id_ed25519 -Encoding ascii - icacls $HOME\.ssh\id_ed25519 /inheritance:r /grant:r "$($env:USERNAME):(F)" - ssh-keyscan -t ed25519 -p 22022 frp-by1.wwvvww.cn | Out-File -FilePath $HOME\.ssh\known_hosts -Encoding ascii + echo $env:SSH_PRIVATE_KEY | Out-File -FilePath C:\Windows\system32\config\systemprofile\.ssh\id_ed25519 -Encoding ascii + icacls C:\Windows\system32\config\systemprofile\.ssh\id_ed25519 /inheritance:r /grant:r "$($env:USERNAME):(F)" + ssh-keyscan -t ed25519 -p 22022 frp-by1.wwvvww.cn | Out-File -FilePath C:\Windows\system32\config\systemprofile\.ssh\known_hosts -Encoding ascii env: SSH_PRIVATE_KEY: ${{ secrets.SSH_PRIVATE_KEY }} - name: Clone repository