Publish RHEL7 compatible nightly release #633
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: Publish RHEL7 compatible nightly release | |
on: | |
schedule: | |
- cron: '0 1 * * *' | |
workflow_dispatch: | |
jobs: | |
build: | |
env: | |
ENVIRONMENT_NAME: rhel7_devel | |
ENVIRONMENT_FILE_PATH: rhel7_devel.yml | |
TEST_FILE: test.sh | |
runs-on: ubuntu-latest | |
name: Build environment | |
steps: | |
- name: Free disk space | |
run: | | |
sudo swapoff -a | |
sudo rm -f /swapfile | |
sudo apt clean | |
docker rmi $(docker image ls -aq) | |
df -h | |
- name: Build environment | |
uses: slaclab/lcls-rhel7-conda-pack@v1.1 | |
# Artifact uploads to a published release on GitHub must remain under 2GB or the job will fail | |
# So we split the final output up here, and can reassemble when downloading it elsewhere | |
- name: Split output artifact to stay under 2GB upload per file limit | |
run: | | |
split -b 1500M -d ${{ env.ENVIRONMENT_NAME }}.tar.gz ${{ env.ENVIRONMENT_NAME }}.tar.gz. | |
- name: Upload artifact to release | |
uses: svenstaro/upload-release-action@v2 | |
with: | |
repo_token: ${{ secrets.GITHUB_TOKEN }} | |
file: ${{ env.ENVIRONMENT_NAME }}.tar.gz.* | |
tag: rhel7-nightly | |
overwrite: true | |
file_glob: true |