Skip to content

Commit

Permalink
chore: server build
Browse files Browse the repository at this point in the history
  • Loading branch information
Zhazhazhu committed Jan 23, 2024
1 parent e8b71b8 commit bee3f8d
Showing 1 changed file with 39 additions and 0 deletions.
39 changes: 39 additions & 0 deletions .github/workflows/server.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: Post to Alibaba Cloud
on:
push:
branches:
- main

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
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 }}

0 comments on commit bee3f8d

Please sign in to comment.