fix config fix in admin and frontend

This commit is contained in:
einhornimmond 2025-05-06 22:28:55 +02:00
parent 66c7108abd
commit 3cf9e96974
4 changed files with 12 additions and 5 deletions

View File

@ -2,7 +2,7 @@
// The whole contents is exposed to the client
// Load Package Details for some default values
import pkg from '../../package'
const pkg = require('../../package')
const version = {
ADMIN_MODULE_PROTOCOL: process.env.ADMIN_MODULE_PROTOCOL ?? 'http',

View File

@ -6,18 +6,22 @@ import Components from 'unplugin-vue-components/vite'
import IconsResolve from 'unplugin-icons/resolver'
import { BootstrapVueNextResolver } from 'bootstrap-vue-next'
import EnvironmentPlugin from 'vite-plugin-environment'
import schema from './src/config/schema'
import CONFIG from './src/config'
import { execSync } from 'node:child_process'
import { existsSync, constants } from 'node:fs'
import { validate, browserUrls } from 'config-schema'
import path from 'node:path'
import { createRequire } from 'node:module'
import dotenv from 'dotenv'
dotenv.config() // load env vars from .env
const require = createRequire(import.meta.url)
const CONFIG = require('./src/config')
export default defineConfig(async ({ command }) => {
const { vitePluginGraphqlLoader } = await import('vite-plugin-graphql-loader')
if (command === 'serve') {

View File

@ -2,7 +2,7 @@
// The whole contents is exposed to the client
// Load Package Details for some default values
import pkg from '../../package'
const pkg = require('../../package')
const constants = {
DECAY_START_TIME: new Date('2021-05-13 17:46:31-0000'), // GMT+0

View File

@ -10,17 +10,20 @@ import { createHtmlPlugin } from 'vite-plugin-html'
import schema from './src/config/schema'
import { execSync } from 'node:child_process'
import { existsSync, constants } from 'node:fs'
import CONFIG from './src/config'
import { validate, browserUrls } from 'config-schema'
import { BootstrapVueNextResolver } from 'bootstrap-vue-next'
import { createRequire } from 'node:module'
import dotenv from 'dotenv'
dotenv.config() // load env vars from .env
import dotenv from 'dotenv'
dotenv.config() // load env vars from .env
const require = createRequire(import.meta.url)
const CONFIG = require('./src/config')
// https://vitejs.dev/config/
export default defineConfig(async ({ command }) => {