Release Droid - Upload GitHub Release Assets #10
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Release Droid - Upload GitHub Release Assets | |
on: | |
workflow_dispatch: | |
inputs: | |
upload_url: | |
description: 'Upload URL' | |
required: true | |
jobs: | |
release: | |
strategy: | |
matrix: | |
python-version: [ 3.8 ] | |
runs-on: ubuntu-latest | |
env: | |
RELEASE_DIR: ".build_output/exported_container" | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Setup Python & Poetry Environment | |
uses: ./.github/actions/prepare_poetry_env | |
- name: Build Poetry | |
run: poetry build | |
- name: Install project whl | |
run: pip install dist/*.whl | |
- name: Install Lua dependencies | |
run: | | |
sudo apt-get install luarocks | |
sudo luarocks install --only-deps *.rockspec | |
- name: Run Lua unit tests and static code analyzer | |
run: poetry run poe lua-tests | |
- name: Release language container | |
run: ./release_language_container.sh "$RELEASE_DIR" | |
- name: Setup integration test environment | |
run: ./scripts/setup_integration_test.sh | |
- name: Poetry run pytest integration tests | |
run: poetry run pytest tests | |
- name: Upload assets to the GitHub release draft | |
uses: shogo82148/actions-upload-release-asset@v1 | |
with: | |
upload_url: ${{ github.event.inputs.upload_url }} | |
asset_path: dist/* | |
# Since the container was built in the pytest run above, no need to rebuilt before the upload. | |
- name: Upload script-language container | |
uses: shogo82148/actions-upload-release-asset@v1 | |
with: | |
upload_url: ${{ github.event.inputs.upload_url }} | |
asset_path: $RELEASE_DIR/* |