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

Feat/ci cd daniel #15

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
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
14 changes: 5 additions & 9 deletions .github/workflows/package.yaml
Original file line number Diff line number Diff line change
@@ -1,15 +1,11 @@
name: Python package and Docker build

name: Python tests and build
on: [push]

jobs:
build:

runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.9", "3.10"]

steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
Expand All @@ -30,15 +26,14 @@ jobs:
- name: Test with pytest
run: |
pytest

docker:
runs-on: ubuntu-latest
steps:
-
name: Set up QEMU
name: Setup QEMU
uses: docker/setup-qemu-action@v2
-
name: Set up Docker Buildx
name: Setup Docker Buildx
uses: docker/setup-buildx-action@v2
-
name: Login to DockerHub
Expand All @@ -51,4 +46,5 @@ jobs:
uses: docker/build-push-action@v3
with:
push: true
tags: markofmadness/mnist-api:latest
tags: ${{ secrets.DOCKERHUB_USERNAME }}/mnist-api:latest