Add serve options to angular.json for development environment
This commit is contained in:
@@ -64,6 +64,15 @@
|
|||||||
},
|
},
|
||||||
"serve": {
|
"serve": {
|
||||||
"builder": "@angular-devkit/build-angular:dev-server",
|
"builder": "@angular-devkit/build-angular:dev-server",
|
||||||
|
"options": {
|
||||||
|
"buildTarget": "client:build:development",
|
||||||
|
"host": "0.0.0.0",
|
||||||
|
"port": 4200,
|
||||||
|
"proxyConfig": "proxy.conf.json",
|
||||||
|
"allowedHosts": [
|
||||||
|
"dev.vincent-guillet.fr"
|
||||||
|
]
|
||||||
|
},
|
||||||
"configurations": {
|
"configurations": {
|
||||||
"production": {
|
"production": {
|
||||||
"buildTarget": "client:build:production"
|
"buildTarget": "client:build:production"
|
||||||
|
|||||||
@@ -1,13 +0,0 @@
|
|||||||
import { defineConfig } from 'vite';
|
|
||||||
|
|
||||||
// Angular utilise Vite en interne — cette config surcharge seulement le serveur dev.
|
|
||||||
export default defineConfig({
|
|
||||||
server: {
|
|
||||||
host: true, // permet 0.0.0.0 => accessible depuis Docker
|
|
||||||
allowedHosts: [
|
|
||||||
'dev.vincent-guillet.fr' // on autorise ton domaine
|
|
||||||
],
|
|
||||||
strictPort: true,
|
|
||||||
port: 4200
|
|
||||||
}
|
|
||||||
});
|
|
||||||
Reference in New Issue
Block a user