From 78bed801e2b4de5b72bba9f9b53ec5845eeddac8 Mon Sep 17 00:00:00 2001 From: Zhazhazhu Date: Wed, 24 Jan 2024 19:34:33 +0800 Subject: [PATCH] chore: remove server work --- .github/workflows/release.yml | 37 +++++++++++++++++++++++++++++++-- .github/workflows/server.yml | 39 ----------------------------------- 2 files changed, 35 insertions(+), 41 deletions(-) delete mode 100644 .github/workflows/server.yml diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 3b8db12..a0f82df 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -15,7 +15,7 @@ jobs: build: [linux, macos, windows] include: - build: linux - os: ubuntu-latest + os: ubuntu-20.04 rust: nightly target: x86_64-unknown-linux-musl archive-name: airnc-linux.tar.gz @@ -53,7 +53,7 @@ jobs: - name: Install musl(linux) if: matrix.build == 'linux' - run: sudo apt-get install -y musl-tools libssl-dev + run: sudo apt install musl-tools libssl-dev -y - name: Build binary run: cargo build --verbose --release --target ${{ matrix.target }} --package airnc @@ -90,3 +90,36 @@ jobs: with: draft: true files: archive/${{ matrix.archive-name }} + + server: + runs-on: ubuntu-latest + + steps: + - name: Checkout repository + uses: actions/checkout@v2 + + - name: Install Rust + uses: actions-rs/toolchain@v1 + with: + toolchain: nightly + profile: minimal + override: true + target: x86_64-unknown-linux-musl + + - name: Install musl + run: sudo apt-get install -y musl-tools + + - name: Build binary + run: cargo build --verbose --release --package airnc-server + env: + RUST_BACKTRACE: 1 + + - name: Post to Alibaba Cloud + uses: easingthemes/ssh-deploy@v2.1.5 + env: + ARGS: "-avz --delete" + SOURCE: "target/release/airnc-server" + TARGET: "${{ secrets.REMOTE_TARGET }}" + REMOTE_HOST: ${{ secrets.REMOTE_HOST }} + REMOTE_USER: ${{ secrets.REMOTE_USER }} + SSH_PRIVATE_KEY: ${{ secrets.SSH_PRIVATE_KEY }} \ No newline at end of file diff --git a/.github/workflows/server.yml b/.github/workflows/server.yml deleted file mode 100644 index ef722e9..0000000 --- a/.github/workflows/server.yml +++ /dev/null @@ -1,39 +0,0 @@ -name: Post to Alibaba Cloud -on: - push: - paths: - - 'crates/server/**' - -jobs: - server: - runs-on: ubuntu-latest - - steps: - - name: Checkout repository - uses: actions/checkout@v2 - - - name: Install Rust - uses: actions-rs/toolchain@v1 - with: - toolchain: nightly - profile: minimal - override: true - target: x86_64-unknown-linux-musl - - - name: Install musl - run: sudo apt-get install -y musl-tools - - - name: Build binary - run: cargo build --verbose --release --package airnc-server - env: - RUST_BACKTRACE: 1 - - - name: Post to Alibaba Cloud - uses: easingthemes/ssh-deploy@v2.1.5 - env: - ARGS: "-avz --delete" - SOURCE: "target/release/airnc-server" - TARGET: "${{ secrets.REMOTE_TARGET }}" - REMOTE_HOST: ${{ secrets.REMOTE_HOST }} - REMOTE_USER: ${{ secrets.REMOTE_USER }} - SSH_PRIVATE_KEY: ${{ secrets.SSH_PRIVATE_KEY }}