chore(deps): bump sass from 1.94.2 to 1.94.3 #550
Workflow file for this run
This file contains hidden or 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
| # Workflow for making a preview deployment of the blog | |
| name: Deploy blog preview | |
| permissions: | |
| contents: read | |
| on: | |
| pull_request: | |
| types: | |
| - opened | |
| - synchronize | |
| - reopened | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref || github.run_id }} | |
| # Default to bash | |
| defaults: | |
| run: | |
| shell: bash | |
| env: | |
| REGISTRY: ghcr.io | |
| IMAGE_NAME: ${{ github.repository }} | |
| jobs: | |
| # Build job | |
| build: | |
| if: ${{ github.actor != 'dependabot[bot]' }} | |
| runs-on: ubuntu-latest | |
| outputs: | |
| image: ${{ steps.docker_image.outputs.image }} | |
| image_repository: ${{ steps.docker_image.outputs.image_repository }} | |
| image_tag: ${{ steps.docker_image.outputs.image_tag }} | |
| permissions: | |
| contents: read | |
| packages: write | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v6 | |
| - name: Docker image metadata | |
| id: meta | |
| uses: docker/metadata-action@v5 | |
| with: | |
| images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }} | |
| tags: type=sha | |
| - name: Extract Docker image name | |
| id: docker_image | |
| env: | |
| IMAGE_TAGS: ${{ steps.meta.outputs.tags }} | |
| run: | | |
| IMAGE=$(echo "$IMAGE_TAGS" | cut -d" " -f1) | |
| IMAGE_REPOSITORY=$(echo "$IMAGE" | cut -d":" -f1) | |
| IMAGE_TAG=$(echo "$IMAGE" | cut -d":" -f2) | |
| echo "image=$IMAGE" >> "$GITHUB_OUTPUT" | |
| echo "image_repository=$IMAGE_REPOSITORY" >> "$GITHUB_OUTPUT" | |
| echo "image_tag=$IMAGE_TAG" >> "$GITHUB_OUTPUT" | |
| - name: Set up node | |
| uses: actions/setup-node@v6 | |
| with: | |
| node-version: "22.18.0" | |
| cache: npm | |
| - name: Set up Docker buildx | |
| uses: docker/setup-buildx-action@v3 | |
| - name: Set up Docker | |
| uses: docker/login-action@v3 | |
| with: | |
| registry: ${{ env.REGISTRY }} | |
| username: ${{ github.actor }} | |
| password: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Install dependencies | |
| run: npm clean-install | |
| - name: Build site | |
| run: npm run build | |
| - name: Build and push Docker image | |
| uses: docker/build-push-action@v6 | |
| with: | |
| context: . | |
| push: true | |
| tags: ${{ steps.meta.outputs.tags }} | |
| labels: ${{ steps.meta.outputs.labels }} | |
| cache-from: type=registry,ref=${{ steps.docker_image.outputs.image_repository }}:buildcache | |
| cache-to: type=registry,ref=${{ steps.docker_image.outputs.image_repository }}:buildcache,mode=max | |
| deploy: | |
| # Deploy job | |
| if: ${{ github.actor != 'dependabot[bot]' }} | |
| runs-on: ubuntu-latest | |
| needs: [build] | |
| # NOTE: using GitHub deploy environments does not work with Azure at the moment | |
| # environment: | |
| # name: renku-blog-ci-${{ github.event.number }} | |
| # url: https://renku-blog-ci-${{ github.event.number }}.dev.renku.ch | |
| permissions: | |
| contents: read | |
| pull-requests: write | |
| id-token: write | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v6 | |
| - name: Set up Helm | |
| uses: azure/setup-helm@v4 | |
| - name: Azure login | |
| uses: azure/login@v2 | |
| with: | |
| client-id: ${{ secrets.CI_RENKU_AZURE_CLIENT_ID }} | |
| tenant-id: ${{ secrets.CI_RENKU_AZURE_TENANT_ID }} | |
| subscription-id: ${{ secrets.CI_RENKU_AZURE_SUBSCRIPTION_ID }} | |
| - name: Set AKS context | |
| uses: azure/aks-set-context@v4 | |
| with: | |
| resource-group: "renku-dev" | |
| cluster-name: "aks-switzerlandnorth-renku-dev" | |
| - name: Deploy helm chart | |
| env: | |
| RELEASE: renku-blog-ci-${{ github.event.number }} | |
| run: | | |
| NAMESPACE=${RELEASE} | |
| HOST=renku-blog-ci-${{ github.event.number }}.dev.renku.ch | |
| IMAGE=$(echo "$IMAGE_TAGS" | cut -d" " -f1) | |
| IMAGE_REPOSITORY=${{ needs.build.outputs.image_repository }} | |
| IMAGE_TAG=${{ needs.build.outputs.image_tag }} | |
| kubectl create namespace ${NAMESPACE} || true | |
| helm upgrade --install ${RELEASE} ./helm-chart/renku-blog \ | |
| --namespace=${NAMESPACE} --timeout 5m --wait --wait-for-jobs \ | |
| --set image.repository=${IMAGE_REPOSITORY} --set image.tag=${IMAGE_TAG} \ | |
| --set ingress.enabled=true --set ingress.hosts[0].host=${HOST} \ | |
| --set ingress.hosts[0].paths[0].path="/" --set ingress.hosts[0].paths[0].pathType="Prefix" \ | |
| --set ingress.tls[0].secretName="${RELEASE}-tls" \ | |
| --set ingress.tls[0].hosts[0]=${HOST} | |
| - name: Find deployment comment | |
| uses: peter-evans/find-comment@v4 | |
| id: find_comment | |
| with: | |
| issue-number: ${{ github.event.pull_request.number }} | |
| # comment-author: "RenkuBot" | |
| comment-author: "github-actions[bot]" | |
| body-includes: You can access the deployment of this PR at | |
| - name: Deployment comment | |
| if: steps.find_comment.outputs.comment-id == '' | |
| uses: peter-evans/create-or-update-comment@v5 | |
| with: | |
| # token: ${{ secrets.RENKUBOT_GITHUB_TOKEN }} | |
| issue-number: ${{ github.event.pull_request.number }} | |
| body: | | |
| You can access the deployment of this PR at https://renku-blog-ci-${{ github.event.number }}.dev.renku.ch | |
| reactions: "rocket" |