Skip to content

Instantly share code, notes, and snippets.

@initcron
Created May 15, 2025 09:02
Show Gist options
  • Save initcron/0e64555ebbd71a93527e54e331f1fa9c to your computer and use it in GitHub Desktop.
Save initcron/0e64555ebbd71a93527e54e331f1fa9c to your computer and use it in GitHub Desktop.
name: Streamlit CI
on:
push:
paths:
- 'streamlit_app/**'
workflow_dispatch:
jobs:
build-and-push:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Log in to DockerHub Container Registry
uses: docker/login-action@v3
with:
registry: docker.io
username: ${{ vars.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push Docker image
uses: docker/build-push-action@v5
with:
context: ./streamlit_app
push: true
tags: docker.io/${{ vars.DOCKERHUB_USERNAME }}/streamlit:latest
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment