在aws中安装angular project时遇到的问题

在aws中安装angular project时遇到的问题,angular,amazon-ec2,Angular,Amazon Ec2,我正在尝试在我的aws中执行npm安装, 我用 ng serve--主机0.0.0.0--端口4200--公共myip.amazonaws.com 我有以下错误: Data path "" should NOT have additional properties(project). Error: Schema validation failed with the following errors: Data path "" should NOT have additional prop

我正在尝试在我的aws中执行npm安装, 我用 ng serve--主机0.0.0.0--端口4200--公共myip.amazonaws.com

我有以下错误:

  Data path "" should NOT have additional properties(project).
Error: Schema validation failed with the following errors:
  Data path "" should NOT have additional properties(project).
    at MergeMapSubscriber._registry.compile.pipe.operators_1.concatMap.validatorResult [as project] (/home/ec2-user/angular/tesis/node_modules/@angular-devkit/core/src/workspace/workspace.js:210:42)
    at MergeMapSubscriber._tryNext (/home/ec2-user/angular/tesis/node_modules/@angular-devkit/core/node_modules/rxjs/internal/operators/mergeMap.js:65:27)
    at MergeMapSubscriber._next (/home/ec2-user/angular/tesis/node_modules/@angular-devkit/core/node_modules/rxjs/internal/operators/mergeMap.js:55:18)
    at MergeMapSubscriber.Subscriber.next (/home/ec2-user/angular/tesis/node_modules/@angular-devkit/core/node_modules/rxjs/internal/Subscriber.js:64:18)
    at MergeMapSubscriber.notifyNext (/home/ec2-user/angular/tesis/node_modules/@angular-devkit/core/node_modules/rxjs/internal/operators/mergeMap.js:84:26)
    at InnerSubscriber._next (/home/ec2-user/angular/tesis/node_modules/@angular-devkit/core/node_modules/rxjs/internal/InnerSubscriber.js:25:21)
    at InnerSubscriber.Subscriber.next (/home/ec2-user/angular/tesis/node_modules/@angular-devkit/core/node_modules/rxjs/internal/Subscriber.js:64:18)
    at MapSubscriber._next (/home/ec2-user/angular/tesis/node_modules/@angular-devkit/core/node_modules/rxjs/internal/operators/map.js:52:26)
    at MapSubscriber.Subscriber.next (/home/ec2-user/angular/tesis/node_modules/@angular-devkit/core/node_modules/rxjs/internal/Subscriber.js:64:18)
    at SwitchMapSubscriber.notifyNext (/home/ec2-user/angular/tesis/node_modules/@angular-devkit/core/node_modules/rxjs/internal/operators/switchMap.js:77:26)
我不知道问题出在哪里

  My actual versions are:
    Package                      Version
    ------------------------------------------------------
@angular-devkit/architect    0.8.1
@angular-devkit/core         0.8.1
@angular-devkit/schematics   0.8.1
@angular/cdk                 6.2.1
@angular/cli                 6.2.1
@angular/material            6.2.1
@schematics/angular          0.8.1
@schematics/update           0.8.1
rxjs                         6.3.2
typescript                   2.9.2
谢谢

您可以使用ng build--prod命令来构建您的应用程序,该应用程序使用生产环境在本地计算机中创建dist文件夹,并且您可以将dist文件夹直接移动到服务器根路径

您的服务器配置文档根路径如下/var/www/html/dist

如果使用apache服务器,请确保添加.htcaccess以重新加载