From 595bc3822ac8fb8298748a48152a4a9db4f45f9c Mon Sep 17 00:00:00 2001 From: Alan Chang Date: Mon, 1 Apr 2024 21:29:52 -0700 Subject: [PATCH] Change env secrets to work with next --- .github/workflows/deploy.yml | 6 +++--- src/app/(main)/resources/page.jsx | 2 +- src/app/(main)/schedule/page.jsx | 2 +- src/app/(main)/workshops/page.jsx | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 4c9b03e..07e8c9f 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -14,9 +14,9 @@ concurrency: cancel-in-progress: false env: - MAINTENANCE_MODE_RESOURCES: ${{ secrets.MAINTENANCE_MODE_RESOURCES }} - MAINTENANCE_MODE_SCHEDULE: ${{ secrets.MAINTENANCE_MODE_SCHEDULE }} - MAINTENANCE_MODE_WORKSHOPS: ${{ secrets.MAINTENANCE_MODE_WORKSHOPS }} + NEXT_PUBLIC_MAINTENANCE_MODE_RESOURCES: ${{ secrets.NEXT_PUBLIC_MAINTENANCE_MODE_RESOURCES }} + NEXT_PUBLIC_MAINTENANCE_MODE_SCHEDULE: ${{ secrets.NEXT_PUBLIC_MAINTENANCE_MODE_SCHEDULE }} + NEXT_PUBLIC_MAINTENANCE_MODE_WORKSHOPS: ${{ secrets.NEXT_PUBLIC_MAINTENANCE_MODE_WORKSHOPS }} jobs: build: diff --git a/src/app/(main)/resources/page.jsx b/src/app/(main)/resources/page.jsx index 01a8deb..3031bb1 100644 --- a/src/app/(main)/resources/page.jsx +++ b/src/app/(main)/resources/page.jsx @@ -41,6 +41,6 @@ import "./Resources.scss"; // ); // } -const Resources = () => process.env.MAINTENANCE_MODE_RESOURCES ? redirect("/") :

Resources

; +const Resources = () => process.env.NEXT_PUBLIC_MAINTENANCE_MODE_RESOURCES ? redirect("/") :

Resources

; export default Resources; diff --git a/src/app/(main)/schedule/page.jsx b/src/app/(main)/schedule/page.jsx index a8455b2..16fd674 100644 --- a/src/app/(main)/schedule/page.jsx +++ b/src/app/(main)/schedule/page.jsx @@ -33,6 +33,6 @@ import "./Schedule.scss"; // // ); -const Schedule = () => process.env.MAINTENANCE_MODE_SCHEDULE ? redirect("/") :

Schedule

; +const Schedule = () => process.env.NEXT_PUBLIC_MAINTENANCE_MODE_SCHEDULE ? redirect("/") :

Schedule

; export default Schedule; diff --git a/src/app/(main)/workshops/page.jsx b/src/app/(main)/workshops/page.jsx index 905f723..c7faf26 100644 --- a/src/app/(main)/workshops/page.jsx +++ b/src/app/(main)/workshops/page.jsx @@ -18,6 +18,6 @@ import "./Workshops.scss"; // ); // }; -const Workshops = () => process.env.MAINTENANCE_MODE_WORKSHOPS ? redirect("/") :

Workshops

; +const Workshops = () => process.env.NEXT_PUBLIC_MAINTENANCE_MODE_WORKSHOPS ? redirect("/") :

Workshops

; export default Workshops;