From df2e4bd3ef162c36d43e0b4c5653337c1066d8ac Mon Sep 17 00:00:00 2001 From: Pranav Malaviya Date: Thu, 9 Dec 2021 00:01:53 +1100 Subject: [PATCH] Add curl request to trigger the publish-ami workflow --- .github/workflows/pypi-upload.yml | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/.github/workflows/pypi-upload.yml b/.github/workflows/pypi-upload.yml index 8a79aee..1ab7bd1 100644 --- a/.github/workflows/pypi-upload.yml +++ b/.github/workflows/pypi-upload.yml @@ -32,6 +32,18 @@ jobs: TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }} run: | twine upload --verbose -u '__token__' dist/* + + # This step triggers the publish-amis workflow here + # https://github.com/tidalmigrations/Infrastructure-templates/blob/main/.github/workflows/publish-images.yml + - name: Trigger publish-ami workflow + run: | + curl -X POST \ + -H "Accept: application/vnd.github.v3+json" \ + -H "Authorization: token ${{ secrets.PERSONAL_ACCESS_TOKEN_GITHUB }}" \ + --data '{"event_type":"publish_amis"}' \ + https://api.github.com/repos/tidalmigrations/Infrastructure-templates/dispatches + + virt_stats: name: Virt Stats PyPI Upload runs-on: ubuntu-latest