-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathnuxt.config.ts
More file actions
87 lines (78 loc) · 2.37 KB
/
nuxt.config.ts
File metadata and controls
87 lines (78 loc) · 2.37 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
import { readFileSync, writeFileSync } from 'fs'
import consola from 'consola'
let https = {}
if (/yes|1|on|true/i.test(`${process.env.SESAME_HTTPS_ENABLED}`)) {
try {
https = {
key: readFileSync(`${process.env.SESAME_HTTPS_PATH_KEY}`, 'utf8'),
cert: readFileSync(`${process.env.SESAME_HTTPS_PATH_CERT}`, 'utf8'),
};
consola.info('[Nuxt] SSL certificates loaded successfully')
} catch (error) {
consola.warn('[Nuxt] Error while reading SSL certificates', error)
}
}
// https://nuxt.com/docs/api/configuration/nuxt-config
export default defineNuxtConfig({
compatibilityDate: '2024-04-03',
devtools: { enabled: true },
modules: ["nuxt-quasar-ui","@nuxt-alt/proxy"],
devServer: {
https,
},
srcDir: "src",
appConfig: {
action: process.env.ACTION || 'change',
userLabel: process.env.USER_LABEL || 'Utilisateur'
},
proxy: {
https: false,
proxies: {
'/management/passwd': {
target: process.env.API_URL,
changeOrigin: true,
changeHost: true,
headers: {Authorization: 'Bearer ' + process.env.API_KEY},
secure: false,
}
},
cors: false
},
quasar: {
config: {
notify:{
type: 'warning',
position: 'center',
timeout:0,
multiLine: true,
html:true,
actions: [
{ label: 'OK', color: 'yellow', handler: () => { /* ... */ } }
]
},
brand: {
primary: process.env.COLOR_PRIMARY || '#1976d2',
secondary: process.env.COLOR_SECONDARY || '#26A69A',
accent: process.env.COLOR_ACCENT || '#9C27B0',
dark: process.env.COLOR_DARK || '#1d1d1d',
'dark-page': process.env.COLOR_DARK_PAGE ||'#121212',
positive: process.env.COLOR_POSITIVE || '#21BA45',
negative: process.env.COLOR_NEGATIVE || '#C10015',
info: process.env.COLOR_INFO || '#31CCEC',
warning: process.env.COLOR_WARNING ||'#F2C037'
}
},
// iconSet: 'material-icons', // Quasar icon set
// lang: 'en-US', // Quasar language pack
// For special cases outside of where the auto-import strategy can have an impact
// (like functional components as one of the examples),
// you can manually specify Quasar components/directives to be available everywhere:
//
// components: [],
// directives: [],
// Quasar plugins
plugins: [
'Notify'
]
}
})