feat: add storage label to all storage metrics (#1234) #15
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: Build Binary | |
on: | |
workflow_dispatch: | |
push: | |
branches: | |
- 'main' | |
paths: | |
- 'src/**' | |
- 'Cargo.toml' | |
- 'Cargo.lock' | |
- 'tests/fixtures/**' | |
- 'static/**' | |
- '.sqlx/**' | |
jobs: | |
build_run_with_importer: | |
name: Run with importer | |
runs-on: ubuntu-latest | |
timeout-minutes: 45 | |
concurrency: | |
group: ${{ github.workflow }}-{{ github.run_id }} | |
cancel-in-progress: true | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Set up Rust | |
run: curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --default-toolchain 1.79 | |
- name: Rust Cache | |
uses: Swatinem/rust-cache@v2 | |
id: cache-cargo | |
with: | |
prefix-key: ${{ runner.os }}-v3-cargo | |
shared-key: artifact | |
cache-provider: "github" | |
save-if: ${{ github.ref_name == 'main' }} | |
- name: Install protoc | |
run: sudo apt-get install -y protobuf-compiler | |
- name: Build | |
run: cargo build --release --bin run-with-importer --features metrics,rocks,kubernetes | |
env: | |
CARGO_PROFILE_RELEASE_DEBUG: 1 | |
LOG_FORMAT: json | |
NO_COLOR: 1 | |
- name: Upload a Build Artifact | |
uses: actions/upload-artifact@v4 | |
id: upload-artifact | |
with: | |
name: stratus-run-with-importer-linux-${{ github.sha }} | |
path: target/release/run-with-importer | |
if-no-files-found: error | |
retention-days: 90 | |
- name: Print outputs | |
run: | | |
echo "Artifact ID: ${{ steps.upload-artifact.outputs.artifact-id }}" | |
echo "Artifact URL: ${{ steps.upload-artifact.outputs.artifact-url }}" | |