Skip to content

Commit

Permalink
upd
Browse files Browse the repository at this point in the history
Signed-off-by: Akira Hayakawa <[email protected]>
  • Loading branch information
akiradeveloper committed Feb 4, 2024
1 parent 3fad0df commit 6bb115a
Show file tree
Hide file tree
Showing 2 changed files with 36 additions and 2 deletions.
18 changes: 16 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,28 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Build

- name: Build (dev)
uses: docker/build-push-action@v5
with:
context: .
push: false
tags: lol-dev:latest
cache-from: type=gha
cache-to: type=gha,mode=max

- name: Build (testapp)
uses: docker/build-push-action@v5
with:
context: .
file: tests/testapp/Dockerfile
push: false
tags: lol-testapp:latest
cache-from: type=gha
cache-to: type=gha,mode=max
cache-to: type=gha,mode=max

- name: Run tests
run: docker compose -f docker-compose.ci.yml run --rm dev cargo test
20 changes: 20 additions & 0 deletions docker-compose-ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
version: '3'

services:
dev:
image: lol-dev:latest
working_dir: /work
volumes:
- ./:/work
- /var/run/docker.sock:/var/run/docker.sock
networks:
- raft-network

testapp:
image: lol-testapp:latest
entrypoint:
- /bin/sh

networks:
raft-network:
driver: bridge

0 comments on commit 6bb115a

Please sign in to comment.