From 37f35c3a134287922c2bf7f49667d699a0128972 Mon Sep 17 00:00:00 2001 From: yoosangwook Date: Thu, 29 May 2025 19:04:11 +0900 Subject: [PATCH] Add cluster start scripts and remove unused Config import in Footer --- src/components/footer/Footer.jsx | 2 -- src/config/config.export.js | 1 + startscriopt-cluster1.js | 2 ++ startscript-cluster2.js | 2 ++ 4 files changed, 5 insertions(+), 2 deletions(-) create mode 100644 startscriopt-cluster1.js create mode 100644 startscript-cluster2.js diff --git a/src/components/footer/Footer.jsx b/src/components/footer/Footer.jsx index 521d3cc9..c62fcf7a 100644 --- a/src/components/footer/Footer.jsx +++ b/src/components/footer/Footer.jsx @@ -1,6 +1,5 @@ 'use client' import LocaleSwitch from '@/components/LocaleSwitch' -import Config from '@/config/config.export' import { usePathname } from 'next/navigation' export default function Footer() { @@ -11,7 +10,6 @@ export default function Footer() {
COPYRIGHT©2024 Hanwha Japan All Rights Reserved. - {Config().mode}
)} diff --git a/src/config/config.export.js b/src/config/config.export.js index 650e1f58..620bd65c 100644 --- a/src/config/config.export.js +++ b/src/config/config.export.js @@ -5,6 +5,7 @@ import configProduction from './config.production' // 클라이언트에서는 이 함수를 사용하여 config 값을 참조합니다. const Config = () => { + console.log('🚀 ~ Config ~ process.env.NEXT_PUBLIC_RUN_MODE:', process.env.NEXT_PUBLIC_RUN_MODE) switch (process.env.NEXT_PUBLIC_RUN_MODE) { case 'local': return configLocal diff --git a/startscriopt-cluster1.js b/startscriopt-cluster1.js new file mode 100644 index 00000000..a1c03b69 --- /dev/null +++ b/startscriopt-cluster1.js @@ -0,0 +1,2 @@ +var exec = require('child_process').exec +exec('yarn start:cluster1', { windowsHide: true }) diff --git a/startscript-cluster2.js b/startscript-cluster2.js new file mode 100644 index 00000000..20fc5f42 --- /dev/null +++ b/startscript-cluster2.js @@ -0,0 +1,2 @@ +var exec = require('child_process').exec +exec('yarn start:cluster2', { windowsHide: true })