Skip to content

Module 5

Module 5 #10

Workflow file for this run

name: Module 5
on:
push:
branches:
- main
pull_request:
branches:
- main
# paths:
# - 'module-4/**'
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
# - name: Login to Docker Hub
# uses: docker/login-action@v1
# with:
# username: ${{ secrets.DOCKER_HUB_USERNAME }}
# password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }}
# - name: Set up Docker Buildx
# uses: docker/setup-buildx-action@v1
# - name: Build app streamlit
# uses: docker/build-push-action@v2
# with:
# context: week-5/
# file: week-5/Dockerfile
# push: true
# target: app-streamlit
# tags: ${{ secrets.DOCKER_HUB_USERNAME }}/app-streamlit:latest
# cache-from: type=registry,ref=${{ secrets.DOCKER_HUB_USERNAME }}/app-streamlit:buildcache
# cache-to: type=registry,ref=${{ secrets.DOCKER_HUB_USERNAME }}/app-streamlit:buildcache,mode=max
# - name: Build app fastapi
# uses: docker/build-push-action@v2
# with:
# context: week-5/
# file: week-5/Dockerfile
# push: true
# target: app-fastapi
# tags: ${{ secrets.DOCKER_HUB_USERNAME }}/app-fastapi:latest
# cache-from: type=registry,ref=${{ secrets.DOCKER_HUB_USERNAME }}/app-fastapi:buildcache
# cache-to: type=registry,ref=${{ secrets.DOCKER_HUB_USERNAME }}/app-fastapi:buildcache,mode=max
# - name: Build app seldon
# uses: docker/build-push-action@v2
# with:
# context: week-5/
# file: week-5/Dockerfile
# push: true
# target: app-seldon
# tags: ${{ secrets.DOCKER_HUB_USERNAME }}/app-seldon:latest
# cache-from: type=registry,ref=${{ secrets.DOCKER_HUB_USERNAME }}/app-seldon:buildcache
# cache-to: type=registry,ref=${{ secrets.DOCKER_HUB_USERNAME }}/app-seldon:buildcache,mode=max
streamlit-docker:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Log in to the Container registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
# - name: Extract metadata (tags, labels) for Docker
# id: meta
# uses: docker/metadata-action@9ec57ed1fcdbf14dcef7dfbe97b2010124a938b7
# with:
# images: ghcr.io/kyryl-opens-ml/app-streamlit
- name: Build and push Docker image
uses: docker/build-push-action@v6
with:
context: module-5/
push: true
target: app-streamlit
tags: ghcr.io/kyryl-opens-ml/app-streamlit:latest