Я не уверен, что я должен вставить для HOST_URL
и других переменных в файле конфигурации при выполнении развертывания
Я пытаюсь развернуть в облаке следующий проект https://github.com/Autodesk-Forge/forge-rcdb.nodejs через Heroku. Я следовал инструкциям, и мои переведенные урны, MongoDB, информация о Forge App и репозиторий Heroku готовы. Тем не менее, после того, как я нажимаю на Heroku и захожу в свой домен, всегда есть 404 не найденных. Мне интересно, не является ли это моей проблемой production.configure.js, потому что я не уверен, как мне заменить переменные HOST_URL
и PORT
.
Исходный файл production.configure.js: https://github.com/Autodesk-Forge/forge-rcdb.nodejs/blob/master/config/production.config.js
Я изменил HOST_URL
= https://hbi -forge-rcdb-test.herokuapp.com
Я сохранил PORT
443 без изменений
Я заменил информацию database
на мою на mlab.
Журнал ошибок: heroku logs --tail
2019-01-16T23:23:56.787369+00:00 app[web.1]: _removedContLen: false,
2019-01-16T23:23:56.787370+00:00 app[web.1]: _removedTE: false,
2019-01-16T23:23:56.787372+00:00 app[web.1]: _contentLength: 0,
2019-01-16T23:23:56.787373+00:00 app[web.1]: _hasBody: true,
2019-01-16T23:23:56.787374+00:00 app[web.1]: _trailer: '',
2019-01-16T23:23:56.787376+00:00 app[web.1]: finished: true,
2019-01-16T23:23:56.787377+00:00 app[web.1]: _headerSent: true,
2019-01-16T23:23:56.787379+00:00 app[web.1]: socket: [TLSSocket],
2019-01-16T23:23:56.787380+00:00 app[web.1]: connection: [TLSSocket],
2019-01-16T23:23:56.787382+00:00 app[web.1]: _header:
2019-01-16T23:23:56.787384+00:00 app[web.1]: 'DELETE /modelderivative/v2/designdata/dXJuOmFkc2sub2JqZWN0czpvcy5vYmplY3Q6Zm9yZ2UtcmNkYi1nYWxsZXJ5LXRtcC1wcm9kL2QxNmUtMWNlZi0xYjc4LnppcA/manifest HTTP/1.1\r\nAuthorization: Bearer eyJhbGciOiJIUzI1NiIsImtpZCI6Imp3dF9zeW1tZXRyaWNfa2V5In0.eyJjbGllbnRfaWQiOiJRRW5mNFVMaXAxRkxHZUE0cVUyNE1ZWHVtQW9hVFJHNiIsImV4cCI6MTU0NzY4NDYzNiwic2NvcGUiOlsiZGF0YTpyZWFkIiwiZGF0YTp3cml0ZSIsImRhdGE6Y3JlYXRlIiwiZGF0YTpzZWFyY2giLCJidWNrZXQ6cmVhZCIsImJ1Y2tldDpjcmVhdGUiLCJidWNrZXQ6ZGVsZXRlIiwidmlld2FibGVzOnJlYWQiXSwiYXVkIjoiaHR0cHM6Ly9hdXRvZGVzay5jb20vYXVkL2p3dGV4cDYwIiwianRpIjoiYnFKM2tXTUdWMnBQT0tSbTBxdmFRSURBMGU1cllBVnlkUDlVdDFTMm52Vk9wRE80eXR5WWZOa2V4Z0doM29HTSJ9.t-cr-4vMZ1ntBuwJTJE3OoG7CZcW4aub5G42XaFwZG8\r\nhost: developer.api.autodesk.com\r\ncontent-length: 0\r\nConnection: close\r\n\r\n',
2019-01-16T23:23:56.787385+00:00 app[web.1]: _onPendingData: [Function: noopPendingOutput],
2019-01-16T23:23:56.787387+00:00 app[web.1]: agent: [Agent],
2019-01-16T23:23:56.787388+00:00 app[web.1]: socketPath: undefined,
2019-01-16T23:23:56.787390+00:00 app[web.1]: timeout: undefined,
2019-01-16T23:23:56.787391+00:00 app[web.1]: method: 'DELETE',
2019-01-16T23:23:56.787393+00:00 app[web.1]: path:
2019-01-16T23:23:56.787395+00:00 app[web.1]: '/modelderivative/v2/designdata/dXJuOmFkc2sub2JqZWN0czpvcy5vYmplY3Q6Zm9yZ2UtcmNkYi1nYWxsZXJ5LXRtcC1wcm9kL2QxNmUtMWNlZi0xYjc4LnppcA/manifest',
2019-01-16T23:23:56.787396+00:00 app[web.1]: _ended: true,
2019-01-16T23:23:56.787398+00:00 app[web.1]: res: [Circular],
2019-01-16T23:23:56.787399+00:00 app[web.1]: aborted: false,
2019-01-16T23:23:56.787401+00:00 app[web.1]: timeoutCb: null,
2019-01-16T23:23:56.787402+00:00 app[web.1]: upgradeOrConnect: false,
2019-01-16T23:23:56.787403+00:00 app[web.1]: parser: null,
2019-01-16T23:23:56.787405+00:00 app[web.1]: maxHeadersCount: null,
2019-01-16T23:23:56.787406+00:00 app[web.1]: [Symbol(isCorked)]: false,
2019-01-16T23:23:56.787408+00:00 app[web.1]: [Symbol(outHeadersKey)]: [Object] },
2019-01-16T23:23:56.787409+00:00 app[web.1]: ntick: true,
2019-01-16T23:23:56.787411+00:00 app[web.1]: response: [Circular],
2019-01-16T23:23:56.787412+00:00 app[web.1]: originalHost: 'developer.api.autodesk.com',
2019-01-16T23:23:56.787414+00:00 app[web.1]: originalHostHeaderName: 'host',
2019-01-16T23:23:56.787415+00:00 app[web.1]: responseContent: [Circular],
2019-01-16T23:23:56.787417+00:00 app[web.1]: _ended: true,
2019-01-16T23:23:56.787418+00:00 app[web.1]: _callbackCalled: true },
2019-01-16T23:23:56.787420+00:00 app[web.1]: toJSON: [Function: responseToJSON],
2019-01-16T23:23:56.787421+00:00 app[web.1]: caseless:
2019-01-16T23:23:56.787422+00:00 app[web.1]: Caseless {
2019-01-16T23:23:56.787424+00:00 app[web.1]: dict:
2019-01-16T23:23:56.787425+00:00 app[web.1]: { 'access-control-allow-credentials': 'true',
2019-01-16T23:23:56.787427+00:00 app[web.1]: 'access-control-allow-origin': '*',
2019-01-16T23:23:56.787428+00:00 app[web.1]: date: 'Wed, 16 Jan 2019 23:23:56 GMT',
2019-01-16T23:23:56.787430+00:00 app[web.1]: 'x-ads-app-identifier': 'platform-viewing-2018.11.01.66.961625f-production',
2019-01-16T23:23:56.787431+00:00 app[web.1]: 'x-ads-duration': '76 ms',
2019-01-16T23:23:56.787433+00:00 app[web.1]: 'x-ads-startup-time': 'Tue Dec 18 03:06:03 UTC 2018',
2019-01-16T23:23:56.787434+00:00 app[web.1]: 'x-ads-troubleshooting':
2019-01-16T23:23:56.787436+00:00 app[web.1]: "The input urn is not authorized. You're not authorized to access this object.",
2019-01-16T23:23:56.787438+00:00 app[web.1]: 'content-length': '0',
2019-01-16T23:23:56.787440+00:00 app[web.1]: connection: 'Close' } },
2019-01-16T23:23:56.787441+00:00 app[web.1]: body: '' }
2019-01-16T23:24:00.210607+00:00 app[web.1]: Cleaning Dir: /app/TMP
2019-01-16T23:24:08.135996+00:00 heroku[router]: at=info method=GET path="/" host=hbi-forge-rcdb-test.herokuapp.com request_id=2840fa63-2b34-4862-aec2-09e4f277fae7 fwd="12.198.253.134" dyno=web.1 connect=1ms service=137ms status=404 bytes=714 protocol=https
2019-01-16T23:38:56.775185+00:00 heroku[web.1]: State changed from up to starting
2019-01-16T23:38:56.607246+00:00 app[api]: Release v15 created by user dyang@herrero.com
2019-01-16T23:38:56.607246+00:00 app[api]: Deploy 6e0b66ae by user dyang@herrero.com
2019-01-16T23:39:06.922653+00:00 heroku[web.1]: Starting process with command `npm start`
2019-01-16T23:39:11.252436+00:00 app[web.1]:
2019-01-16T23:39:11.252468+00:00 app[web.1]: > forge-rcdb@4.0.0 start /app
2019-01-16T23:39:11.252470+00:00 app[web.1]: > node bin/start.js
2019-01-16T23:39:11.252472+00:00 app[web.1]:
2019-01-16T23:39:15.031880+00:00 app[web.1]: uncaughtException
2019-01-16T23:39:15.049942+00:00 app[web.1]: Error: Couldn't find preset "env" relative to directory "/app/webpack"
2019-01-16T23:39:15.049946+00:00 app[web.1]: at /app/node_modules/babel-core/lib/transformation/file/options/option-manager.js:293:19
2019-01-16T23:39:15.049948+00:00 app[web.1]: at Array.map (<anonymous>)
2019-01-16T23:39:15.049951+00:00 app[web.1]: at OptionManager.resolvePresets (/app/node_modules/babel-core/lib/transformation/file/options/option-manager.js:275:20)
2019-01-16T23:39:15.049952+00:00 app[web.1]: at OptionManager.mergePresets (/app/node_modules/babel-core/lib/transformation/file/options/option-manager.js:264:10)
2019-01-16T23:39:15.049954+00:00 app[web.1]: at OptionManager.mergeOptions (/app/node_modules/babel-core/lib/transformation/file/options/option-manager.js:249:14)
2019-01-16T23:39:15.049955+00:00 app[web.1]: at OptionManager.init (/app/node_modules/babel-core/lib/transformation/file/options/option-manager.js:368:12)
2019-01-16T23:39:15.049957+00:00 app[web.1]: at compile (/app/node_modules/babel-register/lib/node.js:103:45)
2019-01-16T23:39:15.049959+00:00 app[web.1]: at loader (/app/node_modules/babel-register/lib/node.js:144:14)
2019-01-16T23:39:15.049961+00:00 app[web.1]: at Object.require.extensions.(anonymous function) [as .js] (/app/node_modules/babel-register/lib/node.js:154:7)
2019-01-16T23:39:15.049963+00:00 app[web.1]: at Module.load (internal/modules/cjs/loader.js:620:32)
2019-01-16T23:39:15.050396+00:00 app[web.1]: Error: Couldn't find preset "env" relative to directory "/app/webpack"
2019-01-16T23:39:15.050399+00:00 app[web.1]: at /app/node_modules/babel-core/lib/transformation/file/options/option-manager.js:293:19
2019-01-16T23:39:15.050401+00:00 app[web.1]: at Array.map (<anonymous>)
2019-01-16T23:39:15.050403+00:00 app[web.1]: at OptionManager.resolvePresets (/app/node_modules/babel-core/lib/transformation/file/options/option-manager.js:275:20)
2019-01-16T23:39:15.050404+00:00 app[web.1]: at OptionManager.mergePresets (/app/node_modules/babel-core/lib/transformation/file/options/option-manager.js:264:10)
2019-01-16T23:39:15.050406+00:00 app[web.1]: at OptionManager.mergeOptions (/app/node_modules/babel-core/lib/transformation/file/options/option-manager.js:249:14)
2019-01-16T23:39:15.050408+00:00 app[web.1]: at OptionManager.init (/app/node_modules/babel-core/lib/transformation/file/options/option-manager.js:368:12)
2019-01-16T23:39:15.050409+00:00 app[web.1]: at compile (/app/node_modules/babel-register/lib/node.js:103:45)
2019-01-16T23:39:15.050411+00:00 app[web.1]: at loader (/app/node_modules/babel-register/lib/node.js:144:14)
2019-01-16T23:39:15.050413+00:00 app[web.1]: at Object.require.extensions.(anonymous function) [as .js] (/app/node_modules/babel-register/lib/node.js:154:7)
2019-01-16T23:39:15.050415+00:00 app[web.1]: at Module.load (internal/modules/cjs/loader.js:620:32)
2019-01-16T23:39:15.408520+00:00 app[web.1]: Connected to MongoDB Database: forge-rcdb
2019-01-16T23:40:51.855605+00:00 heroku[router]: at=info method=GET path="/" host=hbi-forge-rcdb-test.herokuapp.com request_id=14d7e6fc-796c-4ccf-a556-c71156528626 fwd="12.198.253.134" dyno=web.1 connect=0ms service=47ms status=404 bytes=543 protocol=https
2019-01-16T23:44:09.000000+00:00 app[api]: Build started by user dyang@herrero.com
2019-01-16T23:45:46.520453+00:00 app[api]: Release v16 created by user dyang@herrero.com
2019-01-16T23:45:46.520453+00:00 app[api]: Deploy 10c9b461 by user dyang@herrero.com
2019-01-16T23:45:47.085717+00:00 heroku[web.1]: Restarting
2019-01-16T23:45:47.090243+00:00 heroku[web.1]: State changed from up to starting
2019-01-16T23:45:53.274058+00:00 heroku[web.1]: Starting process with command `npm start`
2019-01-16T23:45:55.999215+00:00 app[web.1]:
2019-01-16T23:45:55.999242+00:00 app[web.1]: > forge-rcdb@4.0.0 start /app
2019-01-16T23:45:55.999244+00:00 app[web.1]: > node bin/start.js
2019-01-16T23:45:55.999246+00:00 app[web.1]:
2019-01-16T23:45:57.324079+00:00 app[web.1]: Server listening on PORT: 12592
2019-01-16T23:45:57.324490+00:00 app[web.1]: ENV: production
2019-01-16T23:45:57.325145+00:00 app[web.1]: dist/ directory not found, starting compiler ...
2019-01-16T23:45:57.612313+00:00 heroku[web.1]: State changed from starting to up
2019-01-16T23:46:02.255762+00:00 app[web.1]: Cleaning Dir: /app/TMP
2019-01-16T23:47:07.155089+00:00 heroku[router]: at=info method=GET path="/" host=hbi-forge-rcdb-test.herokuapp.com request_id=a0b128e5-aed8-43f6-91d5-428948cbf72d fwd="12.198.253.134" dyno=web.1 connect=1ms service=55ms status=404 bytes=543 protocol=https
2019-01-17T00:19:34.652699+00:00 heroku[web.1]: Idling
2019-01-17T00:19:34.657780+00:00 heroku[web.1]: State changed from up to down
2019-01-17T00:19:35.935076+00:00 heroku[web.1]: Stopping all processes with SIGTERM
2019-01-17T00:19:36.129738+00:00 heroku[web.1]: Process exited with status 143