Skip to content

Commit

Permalink
Disable restriction to test pushing to test.pypi.org
Browse files Browse the repository at this point in the history
  • Loading branch information
dtrai2 authored Nov 17, 2023
1 parent 249d598 commit 7d18dec
Showing 1 changed file with 30 additions and 29 deletions.
59 changes: 30 additions & 29 deletions .github/workflows/publish-release-to-pypi.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
name: Publish release to PyPi

on:
release:
types: [published]
# on:
# release:
# types: [published]
on: push # remove me again

jobs:
build-wheel-and-tarball:
Expand Down Expand Up @@ -48,36 +49,36 @@ jobs:
path: dist

- name: Publish package distributions to PyPI
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
# if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
uses: pypa/gh-action-pypi-publish@release/v1
with:
repository-url: https://test.pypi.org/legacy/

containerbuild:
strategy:
matrix:
python-version: ["3.9", "3.10", "3.11"]
# containerbuild:
# strategy:
# matrix:
# python-version: ["3.9", "3.10", "3.11"]

runs-on: ubuntu-latest
steps:
- name: Checkout Code
uses: actions/checkout@v3
# runs-on: ubuntu-latest
# steps:
# - name: Checkout Code
# uses: actions/checkout@v3

- name: Login to GitHub Container Registry
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
# - name: Login to GitHub Container Registry
# uses: docker/login-action@v2
# with:
# registry: ghcr.io
# username: ${{ github.actor }}
# password: ${{ secrets.GITHUB_TOKEN }}

- name: Build and Push Docker Image
uses: docker/build-push-action@v3
with:
push: true # Will only build if this is not here
build-args: |
LOGPREP_VERSION=${{ github.ref_name }}
PYTHON_VERSION=${{ matrix.python-version }}
tags: |
ghcr.io/fkie-cad/logprep:py${{ matrix.python-version }}-${{ github.ref_name }}
ghcr.io/fkie-cad/logprep:py${{ matrix.python-version }}-stable
ghcr.io/fkie-cad/logprep:py${{ matrix.python-version }}-latest
# - name: Build and Push Docker Image
# uses: docker/build-push-action@v3
# with:
# push: true # Will only build if this is not here
# build-args: |
# LOGPREP_VERSION=${{ github.ref_name }}
# PYTHON_VERSION=${{ matrix.python-version }}
# tags: |
# ghcr.io/fkie-cad/logprep:py${{ matrix.python-version }}-${{ github.ref_name }}
# ghcr.io/fkie-cad/logprep:py${{ matrix.python-version }}-stable
# ghcr.io/fkie-cad/logprep:py${{ matrix.python-version }}-latest

0 comments on commit 7d18dec

Please sign in to comment.