所以我在 Heroku 中成功上传了我的 GitHub 项目。
-----> Building on the Heroku-20 stack
-----> Using buildpack: heroku/nodejs
-----> Node.js app detected
-----> Creating runtime environment
NPM_CONFIG_LOGLEVEL=error
NODE_VERBOSE=false
NODE_ENV=production
NODE_MODULES_CACHE=true
-----> Installing binaries
engines.node (package.json): unspecified
engines.npm (package.json): unspecified (use default)
Resolving node version 14.x...
Downloading and installing node 14.16.1...
Using default npm version: 6.14.12
-----> Restoring cache
- node_modules is checked into source control and cannot be cached
-----> Installing dependencies
Prebuild detected (node_modules already exists)
Rebuilding any native modules
bcryptjs@2.4.3 /tmp/build_3b3839e2/node_modules/bcryptjs
body-parser@1.19.0 /tmp/build_3b3839e2/node_modules/body-parser
bytes@3.1.0 /tmp/build_3b3839e2/node_modules/bytes
content-type@1.0.4 /tmp/build_3b3839e2/node_modules/content-type
debug@2.6.9 /tmp/build_3b3839e2/node_modules/debug
ms@2.0.0 /tmp/build_3b3839e2/node_modules/ms
depd@1.1.2 /tmp/build_3b3839e2/node_modules/depd
http-errors@1.7.2 /tmp/build_3b3839e2/node_modules/http-errors
inherits@2.0.3 /tmp/build_3b3839e2/node_modules/inherits
setprototypeof@1.1.1 /tmp/build_3b3839e2/node_modules/setprototypeof
statuses@1.5.0 /tmp/build_3b3839e2/node_modules/statuses
toidentifier@1.0.0 /tmp/build_3b3839e2/node_modules/toidentifier
iconv-lite@0.4.24 /tmp/build_3b3839e2/node_modules/iconv-lite
safer-buffer@2.1.2 /tmp/build_3b3839e2/node_modules/safer-buffer
on-finished@2.3.0 /tmp/build_3b3839e2/node_modules/on-finished
ee-first@1.1.1 /tmp/build_3b3839e2/node_modules/ee-first
qs@6.7.0 /tmp/build_3b3839e2/node_modules/qs
raw-body@2.4.0 /tmp/build_3b3839e2/node_modules/raw-body
unpipe@1.0.0 /tmp/build_3b3839e2/node_modules/unpipe
type-is@1.6.18 /tmp/build_3b3839e2/node_modules/type-is
media-typer@0.3.0 /tmp/build_3b3839e2/node_modules/media-typer
mime-types@2.1.29 /tmp/build_3b3839e2/node_modules/mime-types
mime-db@1.46.0 /tmp/build_3b3839e2/node_modules/mime-db
cors@2.8.5 /tmp/build_3b3839e2/node_modules/cors
object-assign@4.1.1 /tmp/build_3b3839e2/node_modules/object-assign
vary@1.1.2 /tmp/build_3b3839e2/node_modules/vary
dotenv@8.2.0 /tmp/build_3b3839e2/node_modules/dotenv
express@4.17.1 /tmp/build_3b3839e2/node_modules/express
accepts@1.3.7 /tmp/build_3b3839e2/node_modules/accepts
negotiator@0.6.2 /tmp/build_3b3839e2/node_modules/negotiator
array-flatten@1.1.1 /tmp/build_3b3839e2/node_modules/array-flatten
content-disposition@0.5.3 /tmp/build_3b3839e2/node_modules/content-disposition
safe-buffer@5.1.2 /tmp/build_3b3839e2/node_modules/safe-buffer
cookie@0.4.0 /tmp/build_3b3839e2/node_modules/cookie
cookie-signature@1.0.6 /tmp/build_3b3839e2/node_modules/cookie-signature
encodeurl@1.0.2 /tmp/build_3b3839e2/node_modules/encodeurl
escape-html@1.0.3 /tmp/build_3b3839e2/node_modules/escape-html
etag@1.8.1 /tmp/build_3b3839e2/node_modules/etag
finalhandler@1.1.2 /tmp/build_3b3839e2/node_modules/finalhandler
parseurl@1.3.3 /tmp/build_3b3839e2/node_modules/parseurl
fresh@0.5.2 /tmp/build_3b3839e2/node_modules/fresh
merge-descriptors@1.0.1 /tmp/build_3b3839e2/node_modules/merge-descriptors
methods@1.1.2 /tmp/build_3b3839e2/node_modules/methods
path-to-regexp@0.1.7 /tmp/build_3b3839e2/node_modules/path-to-regexp
proxy-addr@2.0.6 /tmp/build_3b3839e2/node_modules/proxy-addr
forwarded@0.1.2 /tmp/build_3b3839e2/node_modules/forwarded
ipaddr.js@1.9.1 /tmp/build_3b3839e2/node_modules/ipaddr.js
range-parser@1.2.1 /tmp/build_3b3839e2/node_modules/range-parser
send@0.17.1 /tmp/build_3b3839e2/node_modules/send
destroy@1.0.4 /tmp/build_3b3839e2/node_modules/destroy
mime@1.6.0 /tmp/build_3b3839e2/node_modules/mime
ms@2.1.1 /tmp/build_3b3839e2/node_modules/send/node_modules/ms
serve-static@1.14.1 /tmp/build_3b3839e2/node_modules/serve-static
utils-merge@1.0.1 /tmp/build_3b3839e2/node_modules/utils-merge
jsonwebtoken@8.5.1 /tmp/build_3b3839e2/node_modules/jsonwebtoken
jws@3.2.2 /tmp/build_3b3839e2/node_modules/jws
jwa@1.4.1 /tmp/build_3b3839e2/node_modules/jwa
buffer-equal-constant-time@1.0.1 /tmp/build_3b3839e2/node_modules/buffer-equal-constant-time
ecdsa-sig-formatter@1.0.11 /tmp/build_3b3839e2/node_modules/ecdsa-sig-formatter
lodash.includes@4.3.0 /tmp/build_3b3839e2/node_modules/lodash.includes
lodash.isboolean@3.0.3 /tmp/build_3b3839e2/node_modules/lodash.isboolean
lodash.isinteger@4.0.4 /tmp/build_3b3839e2/node_modules/lodash.isinteger
lodash.isnumber@3.0.3 /tmp/build_3b3839e2/node_modules/lodash.isnumber
lodash.isplainobject@4.0.6 /tmp/build_3b3839e2/node_modules/lodash.isplainobject
lodash.isstring@4.0.1 /tmp/build_3b3839e2/node_modules/lodash.isstring
lodash.once@4.1.1 /tmp/build_3b3839e2/node_modules/lodash.once
ms@2.1.3 /tmp/build_3b3839e2/node_modules/jsonwebtoken/node_modules/ms
semver@5.7.1 /tmp/build_3b3839e2/node_modules/semver
mongoose@5.12.0 /tmp/build_3b3839e2/node_modules/mongoose
@types/mongodb@3.6.9 /tmp/build_3b3839e2/node_modules/@types/mongodb
@types/bson@4.0.3 /tmp/build_3b3839e2/node_modules/@types/bson
@types/node@14.14.34 /tmp/build_3b3839e2/node_modules/@types/node
bson@1.1.5 /tmp/build_3b3839e2/node_modules/bson
kareem@2.3.2 /tmp/build_3b3839e2/node_modules/kareem
mongodb@3.6.4 /tmp/build_3b3839e2/node_modules/mongodb
bl@2.2.1 /tmp/build_3b3839e2/node_modules/bl
readable-stream@2.3.7 /tmp/build_3b3839e2/node_modules/readable-stream
core-util-is@1.0.2 /tmp/build_3b3839e2/node_modules/core-util-is
isarray@1.0.0 /tmp/build_3b3839e2/node_modules/isarray
process-nextick-args@2.0.1 /tmp/build_3b3839e2/node_modules/process-nextick-args
string_decoder@1.1.1 /tmp/build_3b3839e2/node_modules/string_decoder
util-deprecate@1.0.2 /tmp/build_3b3839e2/node_modules/util-deprecate
denque@1.5.0 /tmp/build_3b3839e2/node_modules/denque
require_optional@1.0.1 /tmp/build_3b3839e2/node_modules/require_optional
resolve-from@2.0.0 /tmp/build_3b3839e2/node_modules/resolve-from
mongoose-legacy-pluralize@1.0.2 /tmp/build_3b3839e2/node_modules/mongoose-legacy-pluralize
mpath@0.8.3 /tmp/build_3b3839e2/node_modules/mpath
mquery@3.2.4 /tmp/build_3b3839e2/node_modules/mquery
bluebird@3.5.1 /tmp/build_3b3839e2/node_modules/bluebird
debug@3.1.0 /tmp/build_3b3839e2/node_modules/mquery/node_modules/debug
regexp-clone@1.0.0 /tmp/build_3b3839e2/node_modules/regexp-clone
sliced@1.0.1 /tmp/build_3b3839e2/node_modules/sliced
ms@2.1.2 /tmp/build_3b3839e2/node_modules/mongoose/node_modules/ms
safe-buffer@5.2.1 /tmp/build_3b3839e2/node_modules/mongoose/node_modules/safe-buffer
sift@7.0.1 /tmp/build_3b3839e2/node_modules/sift
morgan@1.10.0 /tmp/build_3b3839e2/node_modules/morgan
basic-auth@2.0.1 /tmp/build_3b3839e2/node_modules/basic-auth
depd@2.0.0 /tmp/build_3b3839e2/node_modules/morgan/node_modules/depd
on-headers@1.0.2 /tmp/build_3b3839e2/node_modules/on-headers
multer@1.4.2 /tmp/build_3b3839e2/node_modules/multer
append-field@1.0.0 /tmp/build_3b3839e2/node_modules/append-field
busboy@0.2.14 /tmp/build_3b3839e2/node_modules/busboy
dicer@0.2.5 /tmp/build_3b3839e2/node_modules/dicer
readable-stream@1.1.14 /tmp/build_3b3839e2/node_modules/dicer/node_modules/readable-stream
isarray@0.0.1 /tmp/build_3b3839e2/node_modules/dicer/node_modules/isarray
string_decoder@0.10.31 /tmp/build_3b3839e2/node_modules/dicer/node_modules/string_decoder
streamsearch@0.1.2 /tmp/build_3b3839e2/node_modules/streamsearch
readable-stream@1.1.14 /tmp/build_3b3839e2/node_modules/busboy/node_modules/readable-stream
isarray@0.0.1 /tmp/build_3b3839e2/node_modules/busboy/node_modules/isarray
string_decoder@0.10.31 /tmp/build_3b3839e2/node_modules/busboy/node_modules/string_decoder
concat-stream@1.6.2 /tmp/build_3b3839e2/node_modules/concat-stream
buffer-from@1.1.1 /tmp/build_3b3839e2/node_modules/buffer-from
typedarray@0.0.6 /tmp/build_3b3839e2/node_modules/typedarray
mkdirp@0.5.5 /tmp/build_3b3839e2/node_modules/mkdirp
minimist@1.2.5 /tmp/build_3b3839e2/node_modules/minimist
xtend@4.0.2 /tmp/build_3b3839e2/node_modules/xtend
memory-pager@1.5.0 /tmp/build_3b3839e2/node_modules/memory-pager
saslprep@1.0.3 /tmp/build_3b3839e2/node_modules/saslprep
sparse-bitfield@3.0.3 /tmp/build_3b3839e2/node_modules/sparse-bitfield
Installing any new modules (package.json)
audited 119 packages in 1.148s
2 packages are looking for funding
run `npm fund` for details
found 0 vulnerabilities
-----> Build
-----> Caching build
- node_modules
-----> Pruning devDependencies
audited 119 packages in 1.143s
2 packages are looking for funding
run `npm fund` for details
found 0 vulnerabilities
-----> Build succeeded!
-----> Discovering process types
Procfile declares types -> (none)
Default types for buildpack -> web
-----> Compressing...
Done: 34.9M
-----> Launching...
Released v5
https://rn-easy-shop.herokuapp.com/ deployed to Heroku
哪个好。接下来我将其显示在屏幕上。
现在我将 Heroku 链接放在 react-native 应用程序中,但没有建立连接。
这是链接
https://rn-easy-shop.herokuapp.com
这是为什么?
应用日志是这个
2021-04-19T15:54:57.862148+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=rn-easy-shop.herokuapp.com request_id=9692d24b-ef50-4a3e-927f-dcb3648a39f1 fwd="3.82.55.86" dyno= connect= service= status=503 bytes= protocol=https
2021-04-19T15:54:58.315297+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=rn-easy-shop.herokuapp.com request_id=3be93391-2e61-4e41-843c-7e41e40ef7c2 fwd="3.82.55.86" dyno= connect= service= status=503 bytes= protocol=https
2021-04-19T15:55:03.915595+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=HEAD path="/" host=rn-easy-shop.herokuapp.com request_id=fbc35bc9-61c3-4bb8-a49a-ee248c8516fd fwd="217.182.175.162" dyno= connect= service= status=503 bytes= protocol=https
2021-04-19T15:55:03.922246+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=HEAD path="/" host=rn-easy-shop.herokuapp.com request_id=5d88d22b-f291-40a6-8312-2f886ec23ef5 fwd="217.182.175.162" dyno= connect= service= status=503 bytes= protocol=https
2021-04-19T15:55:07.708581+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=rn-easy-shop.herokuapp.com request_id=14bfee16-a3f7-4feb-a1f2-dad5238583ee fwd="176.58.227.49" dyno= connect= service= status=503 bytes= protocol=https
2021-04-19T15:55:13.899233+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=rn-easy-shop.herokuapp.com request_id=77578a01-8c8d-4d4a-a92c-adcf37ec1f26 fwd="176.58.227.49" dyno= connect= service= status=503 bytes= protocol=https
2021-04-19T15:58:59.840423+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=rn-easy-shop.herokuapp.com request_id=3f701918-25c4-4d4a-ba46-dd9c5105bb88 fwd="202.189.111.202" dyno= connect= service= status=503 bytes= protocol=https
2021-04-19T15:59:01.203136+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=rn-easy-shop.herokuapp.com request_id=290fffab-131e-4ac2-afc1-3db520b712c6 fwd="202.189.111.202" dyno= connect= service= status=503 bytes= protocol=https
2021-04-19T15:59:08.586965+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=rn-easy-shop.herokuapp.com request_id=4da6fad9-2130-4329-9d4a-2753a375f26e fwd="176.58.227.49" dyno= connect= service= status=503 bytes= protocol=https
2021-04-19T15:59:13.545372+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=rn-easy-shop.herokuapp.com request_id=afb8eebe-4b4d-402d-ac23-12b8f3147670 fwd="176.58.227.49" dyno= connect= service= status=503 bytes= protocol=https
2021-04-19T16:01:12.691837+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=rn-easy-shop.herokuapp.com request_id=d4130830-52d2-4ade-9728-329c7a1d7ce9 fwd="176.58.227.49" dyno= connect= service= status=503 bytes= protocol=https
2021-04-19T16:02:34.983523+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/api/v1/products" host=rn-easy-shop.herokuapp.com request_id=ddc718e3-6d83-4f82-a9f5-aab18d5551bb fwd="176.58.227.49" dyno= connect= service= status=503 bytes= protocol=https
2021-04-19T16:03:48.628898+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=rn-easy-shop.herokuapp.com request_id=943b4963-d778-42d8-875b-0e2366a4e761 fwd="202.189.111.202" dyno= connect= service= status=503 bytes= protocol=https
2021-04-19T16:03:49.265417+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=rn-easy-shop.herokuapp.com request_id=a33bf415-8400-4a0f-9e14-afad60e79b7e fwd="202.189.111.202" dyno= connect= service= status=503 bytes= protocol=https
2021-04-19T16:04:01.796820+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=rn-easy-shop.herokuapp.com request_id=40d1c54e-cb2e-41cf-9008-4290024aff50 fwd="202.189.111.202" dyno= connect= service= status=503 bytes= protocol=https
2021-04-19T16:04:02.409052+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=rn-easy-shop.herokuapp.com request_id=9fd66361-eef8-4167-b101-c2e1aad78f89 fwd="202.189.111.202" dyno= connect= service= status=503 bytes= protocol=https
2021-04-19T16:05:43.000863+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/api/v1/products" host=rn-easy-shop.herokuapp.com request_id=5a83d514-0d47-4270-8020-5c087daef88d fwd="176.58.227.49" dyno= connect= service= status=503 bytes= protocol=https
2021-04-19T16:09:40.637857+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=rn-easy-shop.herokuapp.com request_id=1a253d7a-46aa-46ee-be79-0b8496074fe3 fwd="176.58.227.49" dyno= connect= service= status=503 bytes= protocol=https
谢谢, 提奥。