Skip to content

Commit

Permalink
Merge pull request #99 from near/develop
Browse files Browse the repository at this point in the history
  • Loading branch information
itegulov authored Apr 22, 2023
2 parents 8a8a07d + cbf5d80 commit d3eb8fa
Show file tree
Hide file tree
Showing 47 changed files with 6,559 additions and 606 deletions.
8 changes: 8 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
.git/
.github/
.gitignore
.gitattributes

target/
Dockerfile
.dockerignore
2 changes: 2 additions & 0 deletions .envrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
use flake 'github:DavidM-D/workspaces?dir=rust'
use flake .
33 changes: 30 additions & 3 deletions .github/workflows/integration_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ on:
push:
branches:
- main
- develop
pull_request:
env:
RUSTFLAGS: -D warnings
Expand All @@ -12,13 +13,39 @@ jobs:
name: Test
steps:
- uses: actions/checkout@v3
with:
submodules: 'true'
- uses: actions/checkout@v3
with:
repository: 'near/pagoda-relayer-rs-fastauth'
ref: 'daniyar/custom-entrypoint'
path: 'relayer'
ssh-key: ${{ secrets.RELAYER_DEPLOY_SSH_KEY }}
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Build Docker image
uses: docker/build-push-action@v4
with:
context: relayer
tags: pagoda-relayer-rs-fastauth
load: true
cache-from: type=gha
cache-to: type=gha,mode=max
- name: Install stable toolchain
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
- uses: Swatinem/rust-cache@v1
- name: Build docker image
run: docker build . -t near/mpc-recovery
- name: Install Protoc
uses: arduino/setup-protoc@v1.1.2
- name: Build Docker image
uses: docker/build-push-action@v4
with:
context: .
tags: near/mpc-recovery:latest
load: true
cache-from: type=gha
cache-to: type=gha,mode=max
- name: Test
run: cargo test -p mpc-recovery-integration-tests
run: cargo test -p mpc-recovery-integration-tests
28 changes: 13 additions & 15 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ on:
push:
branches:
- main
- develop
pull_request:
env:
RUSTFLAGS: -D warnings
Expand All @@ -12,35 +13,31 @@ jobs:
name: Test
steps:
- uses: actions/checkout@v3
- name: Install stable toolchain
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
- uses: Swatinem/rust-cache@v1
- name: Unit tests
run: cargo test -p mpc-recovery
lint:
name: Clippy and fmt
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Install stable toolchain with rustfmt and clippy
submodules: 'true'
- name: Install stable toolchain
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
components: rustfmt, clippy
- uses: Swatinem/rust-cache@v1
- name: Install Protoc
uses: arduino/setup-protoc@v1.1.2
- name: Compile
run: cargo check
- name: Test format
run: cargo fmt -- --check
- name: Unit tests
run: cargo test -p mpc-recovery
- name: Test clippy
run: cargo clippy --tests -- -Dclippy::all
audit:
name: Audit
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
submodules: 'true'
- name: Install stable toolchain
uses: actions-rs/toolchain@v1
with:
Expand All @@ -53,4 +50,5 @@ jobs:
uses: actions-rs/cargo@v1
with:
command: audit
args: --ignore RUSTSEC-2020-0071
# Fix RUSTSEC-2023-0001 by upgrading tokio once https://github.com/near/nearcore/issues/8888 is resolved
args: --ignore RUSTSEC-2020-0071 --ignore RUSTSEC-2023-0001
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "mpc-recovery-gcp/googleapis"]
path = mpc-recovery-gcp/googleapis
url = https://github.com/googleapis/googleapis.git
Loading

0 comments on commit d3eb8fa

Please sign in to comment.