2022-04-18 15:49:50 +01:00
|
|
|
name: Blessed.rs
|
|
|
|
on: [push]
|
2022-04-18 15:48:12 +01:00
|
|
|
jobs:
|
|
|
|
build:
|
2022-04-18 18:06:32 +01:00
|
|
|
name: Compile binary
|
2022-04-18 15:48:12 +01:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
- uses: actions-rs/toolchain@v1
|
|
|
|
with:
|
|
|
|
toolchain: stable
|
2022-04-18 17:59:26 +01:00
|
|
|
- name: Compile Release build
|
|
|
|
run: cargo build --release --all-features
|
2022-04-18 18:06:32 +01:00
|
|
|
- name: Upload binary as artifact
|
|
|
|
uses: actions/upload-artifact@v3
|
|
|
|
with:
|
|
|
|
name: blessed-rs-release-binary
|
|
|
|
path: target/release/blessed-rs
|
|
|
|
deploy:
|
|
|
|
name: Deploy to Heroku
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
- name: Download binary artifact
|
|
|
|
uses: actions/download-artifact@v3
|
|
|
|
with:
|
|
|
|
name: blessed-rs-release-binary
|
|
|
|
path: target/release/blessed-rs
|
2022-04-18 17:59:26 +01:00
|
|
|
- name: Deploy to Heroku
|
|
|
|
uses: akhileshns/heroku-deploy@v3.12.12
|
|
|
|
with:
|
2022-04-18 18:06:32 +01:00
|
|
|
heroku_api_key: ${{secrets.HEROKU_API_TOKEN}}
|
2022-04-18 17:59:26 +01:00
|
|
|
heroku_app_name: "blessed-rs" #Must be unique in Heroku
|
|
|
|
heroku_email: "nico@nicoburns.com"
|
|
|
|
usedocker: true
|