Skip to content

Commit 4d568d7

Browse files
authored
build(ci): disable next export, use build time vars for static build (#42)
2 parents 3fa9ad6 + 3c8d04d commit 4d568d7

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

.github/workflows/nextjs.yml

+4-2
Original file line numberDiff line numberDiff line change
@@ -75,8 +75,10 @@ jobs:
7575
run: ${{ steps.detect-package-manager.outputs.manager }} ${{ steps.detect-package-manager.outputs.command }}
7676
- name: Build with Next.js
7777
run: ${{ steps.detect-package-manager.outputs.runner }} next build
78-
- name: Static HTML export with Next.js
79-
run: ${{ steps.detect-package-manager.outputs.runner }} next export
78+
env:
79+
NEXT_PUBLIC_REKOR_DEFAULT_DOMAIN: ${{ secrets.NEXT_PUBLIC_REKOR_DEFAULT_DOMAIN }}
80+
# - name: Static HTML export with Next.js
81+
# run: ${{ steps.detect-package-manager.outputs.runner }} next export
8082
- name: Upload artifact
8183
uses: actions/upload-pages-artifact@v1
8284
with:

next.config.js

+4
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@ const { codecovWebpackPlugin } = require("@codecov/webpack-plugin");
22

33
/** @type {import('next').NextConfig} */
44
const nextConfig = {
5+
env: {
6+
NEXT_PUBLIC_REKOR_DEFAULT_DOMAIN:
7+
process.env.NEXT_PUBLIC_REKOR_DEFAULT_DOMAIN,
8+
},
59
reactStrictMode: true,
610
publicRuntimeConfig: {
711
// remove private env variables

0 commit comments

Comments
 (0)