forked from sigstore/rekor-search-ui
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci(build): re-enable next build action
Signed-off-by: Rachel Yordán <[email protected]>
- Loading branch information
Showing
1 changed file
with
22 additions
and
27 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,8 +29,10 @@ jobs: | |
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
|
||
- name: Checkout 🛎️ | ||
uses: actions/[email protected] | ||
uses: actions/checkout@v4 | ||
|
||
- name: Detect package manager | ||
id: detect-package-manager | ||
run: | | ||
|
@@ -48,21 +50,18 @@ jobs: | |
echo "Unable to determine packager manager" | ||
exit 1 | ||
fi | ||
- name: Setup Node | ||
uses: actions/setup-node@v3 | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: "20" | ||
node-version: "lts/*" | ||
cache: ${{ steps.detect-package-manager.outputs.manager }} | ||
|
||
- name: Setup Pages | ||
uses: actions/configure-pages@v3 | ||
with: | ||
# Automatically inject basePath in your Next.js configuration file and disable | ||
# server side image optimization (https://nextjs.org/docs/api-reference/next/image#unoptimized). | ||
# | ||
# You may remove this line if you want to manage the configuration yourself. | ||
static_site_generator: next | ||
uses: actions/configure-pages@v4 | ||
|
||
- name: Restore cache | ||
uses: actions/cache@v3 | ||
uses: actions/cache@v4 | ||
with: | ||
path: | | ||
.next/cache | ||
|
@@ -71,18 +70,19 @@ jobs: | |
# If source files changed but packages didn't, rebuild from a prior cache. | ||
restore-keys: | | ||
${{ runner.os }}-nextjs-${{ hashFiles('**/package-lock.json', '**/yarn.lock') }}- | ||
- name: Install dependencies | ||
run: ${{ steps.detect-package-manager.outputs.manager }} ${{ steps.detect-package-manager.outputs.command }} | ||
|
||
- name: Build with Next.js | ||
run: ${{ steps.detect-package-manager.outputs.runner }} build && touch ./out/.nojekyll | ||
run: ${{ steps.detect-package-manager.outputs.runner }} next build | ||
env: | ||
NEXT_PUBLIC_REKOR_DEFAULT_DOMAIN: ${{ secrets.NEXT_PUBLIC_REKOR_DEFAULT_DOMAIN }} | ||
# - name: Static HTML export with Next.js | ||
# run: ${{ steps.detect-package-manager.outputs.runner }} next export | ||
# - name: Upload artifact | ||
# uses: actions/upload-pages-artifact@v4 | ||
# with: | ||
# path: ./out | ||
|
||
- name: Upload artifact | ||
uses: actions/upload-pages-artifact@v4 | ||
with: | ||
path: ./out | ||
|
||
# Deployment job | ||
deploy: | ||
|
@@ -92,12 +92,7 @@ jobs: | |
runs-on: ubuntu-latest | ||
needs: build | ||
steps: | ||
# - name: Deploy to GitHub Pages | ||
# id: deployment | ||
# uses: actions/deploy-pages@v4 | ||
- name: Deploy 🚀 | ||
uses: JamesIves/[email protected] | ||
with: | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
branch: main | ||
folder: out | ||
|
||
- name: Deploy to GitHub Pages 🚀 | ||
id: deployment | ||
uses: actions/deploy-pages@v4 |