Skip to content

Commit

Permalink
github action docker image tweaks (#5)
Browse files Browse the repository at this point in the history
* github action docker image tweaks

* pin requirements to specific versions
  • Loading branch information
daneryl authored Feb 20, 2023
1 parent 8d2f336 commit 9829b41
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 12 deletions.
17 changes: 13 additions & 4 deletions .github/workflows/push-docker-image.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,14 @@
name: Create and publish Docker image

on:
workflow_dispatch:
push:
branches: ["main"]
branches:
- 'main'
tags:
- 'v*'
pull_request:
branches:
- 'main'

env:
REGISTRY: ghcr.io
Expand Down Expand Up @@ -33,12 +38,16 @@ jobs:
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
tags: |
type=raw,value=latest,enable={{is_default_branch}}
type=ref,event=branch
type=ref,event=pr
type=semver,pattern={{version}}
type=semver,pattern={{major}}.{{minor}}
- name: Build and push Docker image
uses: docker/build-push-action@v3
with:
context: .
file: Dockerfile
push: true
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
16 changes: 8 additions & 8 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
aiofiles==0.6.0
fastapi~=0.67.0
graypy~=2.1.0
gunicorn
gunicorn==20.1.0
pydantic~=1.8.2
PyRSMQ
python-multipart
PyRSMQ==0.4.5
python-multipart==0.0.5
PyYAML~=5.4.1
redis~=3.5.3
requests~=2.26.0
uvicorn
uvicorn==0.20.0

flake8
pdfplumber
black
sentry-sdk
flake8==6.0.0
pdfplumber==0.7.6
black==23.1.0
sentry-sdk==1.15.0

0 comments on commit 9829b41

Please sign in to comment.