Skip to content

Commit

Permalink
Use services in GH actions
Browse files Browse the repository at this point in the history
  • Loading branch information
mkuratczyk committed Jun 6, 2023
1 parent 1c6af35 commit 295b24b
Showing 1 changed file with 15 additions and 12 deletions.
27 changes: 15 additions & 12 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,23 +34,26 @@ jobs:
strategy:
matrix:
rust-version: [ stable ]
fail-fast: false

services:
rabbitmq:
image: rabbitmq:3-management
ports:
- 15672:15672
- 5672:5672

steps:
- uses: actions/checkout@v3
- uses: dtolnay/rust-toolchain@stable
- name: Setup Rust
uses: dtolnay/rust-toolchain@stable
with:
toolchain: ${{ matrix.rust-version }}

- name: Start RabbitMQ
uses: mkuratczyk/rabbitmq-github-action@v1
with:
version: 'latest'
ports: '15672:15672'
plugins: 'rabbitmq_management'
advanced_config: ${{ github.workspace }}/.github/workflows/ci-rabbitmq.config
- name: Wait for node to start booting
run: sleep 15

- name: Configure broker
run: RABBITHOLE_RABBITMQCTL=DOCKER:${{job.services.rabbitmq.id}} bin/ci/before_build.sh

- name: Run cargo test
run: |
sleep 5
cargo test --workspace --no-fail-fast
run: cargo test --workspace --no-fail-fast

0 comments on commit 295b24b

Please sign in to comment.