Skip to content

Commit

Permalink
chore: Add environment variable to CI
Browse files Browse the repository at this point in the history
* Add RUST_LOG=debug
* Add RUST_BACKTRACE=1
* Format YAML file
  • Loading branch information
StoneDot authored and ryota-sakamoto committed Jul 12, 2023
1 parent ee0e0aa commit 1e90351
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 29 deletions.
1 change: 1 addition & 0 deletions .github/workflows/build_binaries_on_new_releases.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ jobs:
build_dynein_binary:
runs-on: ${{ matrix.os }}
env:
RUST_LOG: debug # Output debug log
RUST_BACKTRACE: 1 # Dump backtrace on panic
strategy:
fail-fast: false
Expand Down
60 changes: 31 additions & 29 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ on:
types: [opened, synchronize, reopened]
push:
branches:
- main
- main

name: CI

Expand All @@ -12,40 +12,42 @@ jobs:
name: Rust project
runs-on: ubuntu-latest
env:
RUST_LOG: debug # Output debug log
RUST_BACKTRACE: 1 # Dump backtrace on panic
DYNEIN_TEST_NO_DOCKER_SETUP: true
# define AWS credentials in environment for test
AWS_ACCESS_KEY_ID: "test"
AWS_SECRET_ACCESS_KEY: "test"
AWS_ACCESS_KEY_ID: test
AWS_SECRET_ACCESS_KEY: test
services:
dynamodb:
# Pinned to the version not to be broken with latest
image: amazon/dynamodb-local:1.22.0
ports:
- 8000:8000
- 8001:8000
- 8000:8000
- 8001:8000
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: 1.69.0
components: rustfmt, clippy
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: 1.69.0
components: rustfmt, clippy
# Pinned to the commit hash of v2.2.1
- uses: Swatinem/rust-cache@6fd3edff6979b79f87531400ad694fb7f2c84b1f
with:
shared-key: build-and-test
- uses: actions-rs/cargo@v1
with:
command: fmt
args: --all -- --check
- uses: actions-rs/clippy-check@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
args: -- -D warnings
- uses: actions-rs/cargo@v1
with:
command: test
args: --no-fail-fast --all-features
- uses: actions-rs/cargo@v1
with:
command: build
args: --release --all-features
- uses: Swatinem/rust-cache@6fd3edff6979b79f87531400ad694fb7f2c84b1f
with:
shared-key: build-and-test
- uses: actions-rs/cargo@v1
with:
command: fmt
args: --all -- --check
- uses: actions-rs/clippy-check@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
args: -- -D warnings
- uses: actions-rs/cargo@v1
with:
command: test
args: --no-fail-fast --all-features
- uses: actions-rs/cargo@v1
with:
command: build
args: --release --all-features

0 comments on commit 1e90351

Please sign in to comment.