chore(deps): update harbor.ukserp.ac.uk/dare/jupyter docker tag to v1… #9
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 | |
on: | |
push: | |
branches: | |
- main | |
permissions: | |
# read needed for changes detection | |
# write needed to author a Github release | |
contents: write | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: false | |
jobs: | |
###################################################################################################################### | |
# Pre-Tasks | |
###################################################################################################################### | |
slack: | |
# Open a new PR thread on Slack for this CI run | |
uses: SwanseaUniversityMedical/workflows/.github/workflows/slack-release-thread.yaml@v3.0.0 | |
with: | |
slack-channel: ${{ vars.SLACK_CHANNEL }} | |
secrets: | |
slack-token: ${{ secrets.SLACK_TOKEN }} | |
changes: | |
# Detect which files have been changed on this PR's full history | |
needs: slack | |
uses: SwanseaUniversityMedical/workflows/.github/workflows/changes.yaml@v3.0.0 | |
with: | |
slack-channel: ${{ vars.SLACK_CHANNEL }} | |
slack-thread: ${{ needs.slack.outputs.thread }} | |
filters: | | |
jupyter-container: | |
- './.github/workflows/on-release.yaml' | |
- 'containers/**' | |
- 'plugins/**' | |
chart: | |
- './.github/workflows/on-release.yaml' | |
- 'charts/**' | |
secrets: | |
slack-token: ${{ secrets.SLACK_TOKEN }} | |
###################################################################################################################### | |
# Container Tasks | |
###################################################################################################################### | |
jupyter-container: | |
# Build the DARE Jupyter container and push it as :rc-1.0.0 | |
needs: | |
- slack | |
- changes | |
if: fromJSON(needs.changes.outputs.changes).jupyter-container == 'true' | |
uses: SwanseaUniversityMedical/workflows/.github/workflows/on-release-container.yaml@v3.0.0 | |
with: | |
job-name: jupyter-container | |
container-registry: ${{ vars.HARBOR_REGISTRY }} | |
container-registry-user: ${{ vars.HARBOR_USER }} | |
container-registry-project: ${{ vars.HARBOR_PROJECT }} | |
container-registry-repo: ${{ vars.HARBOR_REPO }} | |
release-tag-format: 'DARE-Jupyter-Container-${version}' | |
slack-channel: ${{ vars.SLACK_CHANNEL }} | |
slack-thread: ${{ needs.slack.outputs.thread }} | |
build-command: | | |
sudo apt update && | |
sudo apt install python3.8-venv && | |
python -m pip install --user --upgrade build && | |
python -m build --outdir ./dist ./containers/custom-packages/jupyter-cloudbeaver-proxy && | |
python -m build --outdir ./dist ./containers/custom-packages/jupyter-rsession-proxy && | |
docker build -t $IMAGE -f containers/jupyterlab/standard.Dockerfile . | |
secrets: | |
container-registry-token: ${{ secrets.HARBOR_TOKEN }} | |
slack-token: ${{ secrets.SLACK_TOKEN }} | |
###################################################################################################################### | |
# Chart Tasks | |
###################################################################################################################### | |
chart: | |
# Build the chart and push it as x.y.z-rc | |
needs: | |
- slack | |
- changes | |
if: fromJSON(needs.changes.outputs.changes).chart == 'true' | |
uses: SwanseaUniversityMedical/workflows/.github/workflows/on-release-chart.yaml@v3.0.0 | |
with: | |
job-name: chart | |
chart-registry: ${{ vars.HARBOR_REGISTRY }} | |
chart-registry-user: ${{ vars.HARBOR_USER }} | |
chart-registry-project: ${{ vars.HARBOR_PROJECT }} | |
chart-registry-repo: ${{ vars.HARBOR_REPO }} | |
release-tag-format: 'DARE-Jupyter-Helm-${version}' | |
slack-channel: ${{ vars.SLACK_CHANNEL }} | |
slack-thread: ${{ needs.slack.outputs.thread }} | |
chart: charts/** | |
test-command: | | |
helm template $CHART --values charts/jupyter/values.yaml | |
secrets: | |
chart-registry-token: ${{ secrets.HARBOR_TOKEN }} | |
slack-token: ${{ secrets.SLACK_TOKEN }} | |
###################################################################################################################### | |
# Post-Tasks | |
###################################################################################################################### | |
slack-update: | |
# Update the original Slack message with the final workflow status | |
# WARNING! ALL UPSTREAM JOBS MUST BE DECLARED HERE TO REPORT FAILURES CORRECTLY! | |
needs: | |
- slack | |
- changes | |
- jupyter-container | |
- chart | |
uses: SwanseaUniversityMedical/workflows/.github/workflows/slack-release-thread.yaml@v3.0.0 | |
if: always() | |
with: | |
slack-channel: ${{ vars.SLACK_CHANNEL }} | |
slack-thread: ${{ needs.slack.outputs.thread }} | |
status: ${{ contains(join(needs.*.result, ','), 'failure') && ':no_entry:' || ':white_check_mark:' }} | |
secrets: | |
slack-token: ${{ secrets.SLACK_TOKEN }} |