File tree Expand file tree Collapse file tree 2 files changed +49
-0
lines changed Expand file tree Collapse file tree 2 files changed +49
-0
lines changed Original file line number Diff line number Diff line change 1+ name : release
2+ on :
3+ push :
4+ tags : ['v*']
5+ permissions :
6+ contents : write
7+ packages : write
8+ jobs :
9+ build-publish :
10+ runs-on : ubuntu-latest
11+ steps :
12+ - uses : actions/checkout@v4
13+ - uses : actions/setup-python@v5
14+ with : { python-version: '3.12' }
15+ - name : Build
16+ run : |
17+ python -m pip install -U pip build
18+ python -m build
19+ - uses : actions/upload-artifact@v4
20+ with : { name: dist, path: dist/* }
21+ - name : Publish to PyPI
22+ if : startsWith(github.ref, 'refs/tags/v') && secrets.PYPI_API_TOKEN != ''
23+ uses : pypa/gh-action-pypi-publish@release/v1
24+ with :
25+ user : __token__
26+ password : ${{ secrets.PYPI_API_TOKEN }}
27+ publish-ghcr :
28+ needs : build-publish
29+ runs-on : ubuntu-latest
30+ permissions :
31+ contents : read
32+ packages : write
33+ steps :
34+ - uses : actions/checkout@v4
35+ - uses : docker/login-action@v3
36+ with :
37+ registry : ghcr.io
38+ username : ${{ github.actor }}
39+ password : ${{ secrets.GITHUB_TOKEN }}
40+ - uses : docker/build-push-action@v6
41+ with :
42+ context : .
43+ push : true
44+ tags : ghcr.io/${{ github.repository }}:latest,ghcr.io/${{ github.repository }}:${{ github.ref_name }}
Original file line number Diff line number Diff line change 1+ FROM python:3.12-slim
2+ WORKDIR /app
3+ COPY . /app
4+ RUN pip install --no-cache-dir .
5+ ENTRYPOINT ["python" ,"-m" ,"diff_risk_dashboard" ]
You can’t perform that action at this time.
0 commit comments