Push torchserve nightly #982
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: Push torchserve nightly | |
on: | |
# run every day at 11:15am | |
schedule: | |
- cron: '15 11 * * *' | |
workflow_dispatch: | |
jobs: | |
nightly: | |
runs-on: ubuntu-20.04 | |
steps: | |
- name: Setup Conda | |
uses: s-weigand/setup-conda@v1 | |
with: | |
activate-conda: true | |
update-conda: false | |
python-version: "3.9" | |
- run: conda --version | |
- run: conda install -y conda-build anaconda-client | |
- name: Checkout TorchServe | |
uses: actions/checkout@v3 | |
with: | |
submodules: recursive | |
- name: Install dependencies | |
run: | | |
python ts_scripts/install_dependencies.py --environment=dev | |
pip install -e . | |
- name: Setup Java 17 | |
uses: actions/setup-java@v2 | |
with: | |
distribution: 'zulu' | |
java-version: '17' | |
- name: Build PyPI & conda nightly binaries | |
run: python binaries/build.py --nightly | |
- name: Push conda nightly binaries | |
env: | |
ANACONDA_API_TOKEN: ${{ secrets.CONDA_NIGHTLY_TOKEN }} | |
run: python binaries/upload.py --upload-conda-packages | |
- name: Push PyPI nightly binaries | |
env: | |
TWINE_PASSWORD: ${{ secrets.PYPI_TOKEN }} | |
run: python binaries/upload.py --upload-pypi-packages | |
- name: Open issue on failure | |
if: ${{ failure() && github.event_name == 'schedule' }} | |
uses: dacbd/create-issue-action@v1 | |
with: | |
token: ${{ secrets.GITHUB_TOKEN }} | |
title: Nightly Build failed | |
body: Commit ${{ github.sha }} daily scheduled [CI run](https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}) failed, please check why | |
assignees: '' |