Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added deployment. #13

Merged
merged 1 commit into from
Aug 3, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
51 changes: 46 additions & 5 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
name: Build
on:
push:
branches: [ "main" ]
workflow_run:
workflows: ["Run Tests"]
branches: [main]
types:
- completed
env:
CARGO_TERM_COLOR: always
jobs:
Expand All @@ -24,7 +27,19 @@ jobs:
with:
name: game_cheetah_linux
path: target/release/bundle/deb/game_cheetah_*.deb

- uses: actions/download-artifact@v3
with:
name: game_cheetah_linux
path: distfiles
- name: Copy file to server
uses: appleboy/scp-action@v0.1.4
with:
host: ${{ secrets.HOST }}
username: ${{ secrets.USERNAME }}
password: ${{ secrets.PASSWORD }}
port: ${{ secrets.PORT }}
source: distfiles/*
target: game_cheetah
build_osx:
runs-on: macos-latest
steps:
Expand All @@ -39,7 +54,20 @@ jobs:
with:
name: game_cheetah_osx
path: target/release/game_cheetah

- uses: actions/download-artifact@v3
with:
name: game_cheetah_osx
path: distfiles
- name: Copy file to server
uses: appleboy/scp-action@v0.1.4
with:
host: ${{ secrets.HOST }}
username: ${{ secrets.USERNAME }}
password: ${{ secrets.PASSWORD }}
port: ${{ secrets.PORT }}
source: distfiles/*
target: game_cheetah

build_windows:
runs-on: windows-latest
steps:
Expand All @@ -54,4 +82,17 @@ jobs:
with:
name: game_cheetah_windows
path: target/release/game_cheetah.exe

- uses: actions/download-artifact@v3
with:
name: game_cheetah_windows
path: distfiles
- name: Copy file to server
uses: appleboy/scp-action@v0.1.4
with:
host: ${{ secrets.HOST }}
username: ${{ secrets.USERNAME }}
password: ${{ secrets.PASSWORD }}
port: ${{ secrets.PORT }}
source: distfiles/*
target: game_cheetah

Loading