2017-05-04 8 views
0

AppEngine에 배포하려는 Node.JS 응용 프로그램이 있습니다.main.js와 다른 디렉토리에 app.yaml이 있습니까?

Beginning deployment of service [default]... 
Building and pushing image for service [default] 
ERROR: node.js checker: Neither "start" in the "scripts" section of "package.json" nor the "server.js" file were found. 
ERROR: (gcloud.app.deploy) Your application does not satisfy all of the requirements for a runtime of type [nodejs]. Please correct the errors and try again. 

이 폴더 구조로이 말이 : 순간 나는 다음과 같은 오류가 점점 오전

  • 클라이언트
  • 서버
    • main.js를
  • app.yaml

본인의 클라이언트 코드와 서버 코드에 대한 별도의 폴더가 있습니다. app.yaml 파일을 서버 폴더 안에 넣으면 배포가 작동하지만 앱에 액세스하려고 할 때 배포에 포함되지 않았으므로 클라이언트 파일을 찾을 수 없습니다.

어쨌든 app.yaml에서 구성하거나 앱을 리팩토링해야합니까?

답변

0

실제로 응용 프로그램이 필요한 패키지 .json을 루트 디렉토리에 ... 시작 스크립트를 넣으십시오. start:node server/main.js