Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Retest the deployment #9

Merged
merged 7 commits into from
Jan 22, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
name: build
run-name: 🚀 Build
run-name: 🏗️ Build
on:
push:
branches:
- main
- master
- release/**

pull_request:
branches:
- main
- master
- release/**

permissions:
Expand All @@ -19,7 +19,7 @@ concurrency:

jobs:
build:
name: 🚀 Build
name: 🏗️ Build
runs-on: ubuntu-latest
steps:
- name: 🛎️ Checkout
Expand Down
22 changes: 8 additions & 14 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -1,23 +1,17 @@
name: deploy
run-name: 🚀 Deploy

on:
workflow_run:
workflows: ["build"]
branches: ["main", "release/*"]
types:
workflows: [build]
branches: [master]
types:
- completed

env:
DEPLOY_PREVIEW: ${{ github.event.workflow_run.event == 'pull_request' }}
ARTIFACT_NAME: "build-artifact-${{ github.sha }}"



jobs:
deploy:
# Only run if the build was successful
if: ${{ github.event.workflow_run.conclusion == 'success' }}

if: ${{ github.event.workflow_run.conclusion == 'success' && github.ref == 'refs/heads/master' }}
name: 🚀 Deploy
runs-on: ubuntu-latest
environment:
Expand All @@ -30,12 +24,12 @@ jobs:
id-token: write

steps:
- name: Deploy to GitHub Pages
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
with:
artifact_name: ${{ env.ARTIFACT_NAME}}
preview: ${{ env.DEPLOY_PREVIEW }}
artifact_name: "build-artifact-${{ github.sha }}"
preview: false

- name: Get the URL for the deployment
run: echo "${{ steps.deployment.outputs.page_url }}"