fix: Update ci not releasing jupyterhub container (#65) #16
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: | |
changes: | |
# Detect which files have been changed on this PR's full history | |
uses: SwanseaUniversityMedical/workflows/.github/workflows/changes-release.yaml@v4.3.0 | |
with: | |
slack-channel: ${{ vars.SLACK_CHANNEL }} | |
filters: | | |
jupyter-container: | |
- './.github/workflows/on-release.yaml' | |
- 'containers/jupyterlab/**' | |
- 'containers/custom-packages/**' | |
- 'containers/files/**' | |
jupyterhub-container: | |
- './.github/workflows/on-release.yaml' | |
- 'containers/jupyterhub/**' | |
- 'containers/custom-packages/**' | |
- 'containers/files/**' | |
secrets: | |
slack-token: ${{ secrets.SLACK_TOKEN }} | |
jupyter-container: | |
# Build the DARE Jupyter container and push it as :rc-1.0.0 | |
needs: changes | |
if: fromJSON(needs.changes.outputs.changes).jupyter-container == 'true' | |
uses: SwanseaUniversityMedical/workflows/.github/workflows/on-release-container.yaml@v4.3.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: jupyter | |
release-tag-format: 'DARE-Jupyter-Container-${version}' | |
slack-channel: ${{ vars.SLACK_CHANNEL }} | |
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 }} | |
jupyterhub-container: | |
# Build the DARE Jupyter container and push it as :rc-1.0.0 | |
needs: changes | |
if: fromJSON(needs.changes.outputs.changes).jupyterhub-container == 'true' | |
uses: SwanseaUniversityMedical/workflows/.github/workflows/on-release-container.yaml@v4.3.0 | |
with: | |
job-name: jupyterhub-container | |
container-registry: ${{ vars.HARBOR_REGISTRY }} | |
container-registry-user: ${{ vars.HARBOR_USER }} | |
container-registry-project: ${{ vars.HARBOR_PROJECT }} | |
container-registry-repo: jupyterhub | |
release-tag-format: 'DARE-Jupyterhub-Container-${version}' | |
slack-channel: ${{ vars.SLACK_CHANNEL }} | |
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/jupyterhub/Dockerfile . | |
secrets: | |
container-registry-token: ${{ secrets.HARBOR_TOKEN }} | |
slack-token: ${{ secrets.SLACK_TOKEN }} |