enso/.github/workflows/nightly.yml

60 lines
1.8 KiB
YAML
Raw Normal View History

name: Nightly Release CI
env:
2021-08-12 17:55:23 +03:00
# Specifies how many nightly releases should be kept. Any older releases are removed.
NIGHTLIES_TO_KEEP: 20
2022-02-21 18:09:48 +03:00
GITHUB_TOKEN: ${{ github.token }}
2022-02-21 18:09:48 +03:00
# To prevent race conditions, we allow only a single release workflow at the same time.
concurrency: "releases"
2022-02-21 18:09:48 +03:00
on:
schedule:
- cron: "0 4 * * 2-6" # 4am (UTC) from Tuesday to Saturday (i.e. after every workday)
workflow_dispatch:
jobs:
2022-02-21 18:09:48 +03:00
prepare:
runs-on: [self-hosted]
outputs:
2022-02-21 18:09:48 +03:00
ENSO_VERSION: ${{ steps.prepare-step.outputs.ENSO_VERSION }}
ENSO_RELEASE_ID: ${{ steps.prepare-step.outputs.ENSO_RELEASE_ID }}
steps:
2022-02-21 18:09:48 +03:00
- uses: enso-org/ci-build/actions/install@deployed
- run: enso-build enso --kind nightly create-release
id: prepare-step
build:
2022-02-21 18:09:48 +03:00
needs: prepare
env:
ENSO_VERSION: ${{needs.prepare.outputs.ENSO_VERSION}}
ENSO_RELEASE_ID: ${{needs.prepare.outputs.ENSO_RELEASE_ID}}
runs-on: ${{ matrix.os }}
strategy:
matrix:
2022-02-21 18:09:48 +03:00
os:
- [macos-latest]
- [self-hosted, Windows, engine]
- [self-hosted, Linux, engine]
fail-fast: false
steps:
2022-02-21 18:09:48 +03:00
- uses: enso-org/ci-build/actions/install@deployed
- run: enso-build enso --kind nightly upload-asset
finish:
runs-on: [self-hosted]
needs: [prepare, build]
env:
ENSO_VERSION: ${{needs.prepare.outputs.ENSO_VERSION}}
ENSO_RELEASE_ID: ${{needs.prepare.outputs.ENSO_RELEASE_ID}}
steps:
- uses: enso-org/ci-build/actions/install@deployed
- name: Prepare release
run: enso-build enso --kind nightly publish-release
env:
2022-02-21 18:09:48 +03:00
GITHUB_TOKEN: ${{ github.token }}
AWS_ACCESS_KEY_ID: ${{ secrets.ARTEFACT_S3_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.ARTEFACT_S3_SECRET_ACCESS_KEY }}
AWS_REGION: us-west-1