Perps Companion Docker Image #69
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Perps Companion Docker Image | |
on: | |
workflow_dispatch: | |
schedule: | |
# For cache, run at 9 AM UTC every 5th day of month | |
- cron: "0 9 */5 * *" | |
env: | |
CARGO_TERM_COLOR: always | |
CARGO_INCREMENTAL: 0 | |
CARGO_NET_RETRY: 10 | |
RUST_BACKTRACE: short | |
RUSTUP_MAX_RETRIES: 10 | |
jobs: | |
companion-image: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: extractions/setup-just@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
just-version: 1.16.0 | |
- name: Log in to the Container registry | |
uses: docker/login-action@f054a8b539a109f9f41c372932f1ae047eff08c9 | |
with: | |
registry: ghcr.io | |
username: ${{ github.actor }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
- uses: dtolnay/rust-toolchain@master | |
with: | |
toolchain: 1.71.0 | |
components: rustfmt, clippy | |
targets: x86_64-unknown-linux-musl | |
- uses: Swatinem/rust-cache@v2 | |
with: | |
workspaces: | | |
. | |
- name: Dependencies | |
run: sudo apt install musl-tools -y | |
- name: Build companion binary | |
run: just cargo-companion-release | |
- name: Download health-check | |
run: just download-health-check | |
env: | |
LEVANA_DEVOPS_REPO_PAT: ${{ secrets.LEVANA_DEVOPS_REPO_PAT }} | |
- name: Build image | |
run: just build-companion-image | |
- name: Push image | |
run: just push-companion-image | |
if: ${{ github.event_name != 'schedule' }} |