added t1w preprocess pipeline #88
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
# This workflows will upload a Python Package using Twine when a release is created | |
# For more information see: https://help.github.com/en/actions/language-and-framework-guides/using-python-with-github-actions#publishing-to-package-registries | |
name: Build release | |
on: | |
push: | |
branches: [ main, develop ] | |
tags: [ '*' ] | |
pull_request: | |
branches: [ main, develop ] | |
workflow_dispatch: # Allow manual triggering by a user with write access to this repo | |
jobs: | |
deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Removed unnecessary tools to free space | |
run: | | |
sudo rm -rf /usr/share/dotnet | |
sudo rm -rf "$AGENT_TOOLSDIRECTORY" | |
- name: Checkout | |
uses: actions/checkout@v2 | |
- name: Get release tag | |
run: | | |
git fetch --prune --unshallow | |
echo "RELEASE=`echo $(git describe --tags --abbrev=0)`" >> $GITHUB_ENV | |
- name: Unset header | |
# checkout@v2 adds a header that makes branch protection report errors | |
# because the Github action bot is not a collaborator on the repo | |
run: git config --local --unset http.https://github.com/.extraheader | |
- name: Set up Python | |
uses: actions/setup-python@v2 | |
with: | |
python-version: '3.11' | |
- name: Update build tools | |
run: python -m pip install --upgrade pip | |
- name: Install dependencies | |
run: pip install -r requirements.txt | |
- uses: docker/login-action@v2 | |
with: | |
registry: ghcr.io | |
username: ${{ github.actor }} | |
password: ${{ secrets.GITHUB_TOKEN }} # - must be in GitHub Secrets! | |
- name: Check for tagged release | |
id: deployable | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags') | |
run: echo "PUSH='--push'" | |
- name: Build and push container images | |
env: | |
PUSH: "${{ steps.deployable.outputs.PUSH }}" | |
run: > | |
pipeline2app make xnat ./specs/australian-imaging-service/mri/human/neuro/t1w/preprocess.yaml | |
--registry ghcr.io --check-registry --clean-up --loglevel info | |
--resources-dir ./resources --spec-root ./specs --source-package . $PUSH | |
# --release pipelines-metapackage $RELEASE --tag-latest |