Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CI: make worflows re-usable #66

Merged
merged 1 commit into from
Feb 18, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions .github/workflows/docker-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,18 +64,18 @@ jobs:
steps:
- uses: actions/checkout@v3
- uses: docker/setup-qemu-action@v2
- uses: docker/setup-buildx-action@2dd22fa31c04297d369158eb483250f578504a9f
- uses: docker/setup-buildx-action@v2.4.1

- name: Start containers
run: docker-compose up --build --force-recreate --detach
run: docker-compose up --build --force-recreate --detach opi-test

- name: Run Tests
run: |
set -x
name=$(docker-compose ps | grep opi-smbios-test | awk '{print $1}')
name=$(docker-compose ps | grep opi-test | awk '{print $1}')
rc=$(docker wait "${name}")
if [ "${rc}" != "0" ]; then
echo "opi-smbios-test failed:"
echo "opi-test failed:"
docker logs "${name}"
exit 1
fi
Expand All @@ -86,4 +86,4 @@ jobs:

- name: Stop containers
if: always()
run: docker-compose down
run: docker-compose down --volumes --remove-orphans
1 change: 1 addition & 0 deletions .github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ name: Go

on:
workflow_dispatch:
workflow_call:
push:
branches: [ "main" ]
pull_request:
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/linters.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ name: Linters

on:
workflow_dispatch:
workflow_call:
push:
branches: [ main ]
pull_request:
Expand Down
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ services:
healthcheck:
test: grpcurl -plaintext localhost:50051 list || exit 1

opi-smbios-test:
opi-test:
image: namely/grpc-cli
networks:
- opi
Expand Down