我正在尝试在远程服务器上开发Gatsby应用程序。
我从另一位开发人员那里获得了该盖茨比应用程序的源代码,并且适用于他们。所以我做了一个git init
并将代码复制到了我的遥控器上。然后我想运行它,因此我使用npm install
安装了NPM要求,然后由于它是远程的,所以执行了此操作:
MYUSER@MYREMOTE:/var/www/myGatsbyReactApp$ gatsby develop -H MYIP -p 8016
success open and validate gatsby-config — 0.212 s
success load plugins — 8.427 s
success onPreInit — 46.518 s
success delete html and css files from previous builds — 1.633 s
info One or more of your plugins have changed since the last time you ran Gatsby. As
a precaution, we're deleting your site's cache to ensure there's not any stale
data
success initialize cache — 1.048 s
success copy gatsby files — 1.038 s
success onPreBootstrap — 0.585 s
success source and transform nodes — 76.631 s
success building schema — 63.318 s
success createPages — 0.001 s
success createPagesStatefully — 0.194 s
success onPreExtractQueries — 0.011 s
success update schema — 0.293 s
success extract queries from components — 0.306 s
success run graphql queries — 1.745 s — 7/7 4.02 queries/second
success write out page data — 0.021 s
success write out redirect data — 0.002 s
success onPostBootstrap — 0.002 s
info bootstrap finished - 208.725 s
DONE Compiled successfully in 4422ms 22:00:32
You can now view gatsby-universal in the browser.
http://MYIP:8016/
View GraphiQL, an in-browser IDE, to explore your site's data and schema
http://MYIP/___graphql
MYIP
是我的遥控器的IP地址。即使它说我可以访问它,也总是超时。当我监视该端口8016
上的网络时,它正在发送length 0
,我收集到的响应是一个空响应,这就是为什么它超时的原因:
22:09:24.108816 IP c-MYLOCALIP.63915 > MYREMOTEIP.8016: Flags [S], seq 4290212894, win 17520, options [mss 1460,nop,wscale 8,nop,nop,sackOK], length 0
22:09:24.113004 IP c-MYLOCALIP.63916 > MYREMOTEIP.8016: Flags [S], seq 3512642312, win 17520, options [mss 1460,nop,wscale 8,nop,nop,sackOK], length 0
22:09:24.362486 IP c-MYLOCALIP.63917 > MYREMOTEIP.8016: Flags [S], seq 611913385, win 17520, options [mss 1460,nop,wscale 8,nop,nop,sackOK], length 0
22:09:41.142543 IP c-MYLOCALIP.63954 > MYREMOTEIP.8016: Flags [S], seq 4112681510, win 17520, options [mss 1460,nop,wscale 8,nop,nop,sackOK], length 0
22:09:41.147253 IP c-MYLOCALIP.63955 > MYREMOTEIP.8016: Flags [S], seq 2774873338, win 17520, options [mss 1460,nop,wscale 8,nop,nop,sackOK], length 0
22:09:41.392978 IP c-MYLOCALIP.63958 > MYREMOTEIP.8016: Flags [S], seq 1874608944, win 17520, options [mss 1460,nop,wscale 8,nop,nop,sackOK], length 0
22:09:44.140037 IP c-MYLOCALIP.63954 > MYREMOTEIP.8016: Flags [S], seq 4112681510, win 17520, options [mss 1460,nop,wscale 8,nop,nop,sackOK], length 0
22:09:44.144644 IP c-MYLOCALIP.63955 > MYREMOTEIP.8016: Flags [S], seq 2774873338, win 17520, options [mss 1460,nop,wscale 8,nop,nop,sackOK], length 0
22:09:44.399772 IP c-MYLOCALIP.63958 > MYREMOTEIP.8016: Flags [S], seq 1874608944, win 17520, options [mss 1460,nop,wscale 8,nop,nop,sackOK], length 0
22:09:50.143759 IP c-MYLOCALIP.63954 > MYREMOTEIP.8016: Flags [S], seq 4112681510, win 17520, options [mss 1460,nop,wscale 8,nop,nop,sackOK], length 0
22:09:50.148505 IP c-MYLOCALIP.63955 > MYREMOTEIP.8016: Flags [S], seq 2774873338, win 17520, options [mss 1460,nop,wscale 8,nop,nop,sackOK], length 0
22:09:50.404135 IP c-MYLOCALIP.63958 > MYREMOTEIP.8016: Flags [S], seq 1874608944, win 17520, options [mss 1460,nop,wscale 8,nop,nop,sackOK], length 0
22:10:19.810010 IP c-MYLOCALIP.64013 > MYREMOTEIP.8016: Flags [S], seq 486748091, win 17520, options [mss 1460,nop,wscale 8,nop,nop,sackOK], length 0
22:10:19.821710 IP c-MYLOCALIP.64014 > MYREMOTEIP.8016: Flags [S], seq 565479336, win 17520, options [mss 1460,nop,wscale 8,nop,nop,sackOK], length 0
22:10:20.064654 IP c-MYLOCALIP.64015 > MYREMOTEIP.8016: Flags [S], seq 1086832564, win 17520, options [mss 1460,nop,wscale 8,nop,nop,sackOK], length 0
22:10:22.810999 IP c-MYLOCALIP.64013 > MYREMOTEIP.8016: Flags [S], seq 486748091, win 17520, options [mss 1460,nop,wscale 8,nop,nop,sackOK], length 0
22:10:22.822665 IP c-MYLOCALIP.64014 > MYREMOTEIP.8016: Flags [S], seq 565479336, win 17520, options [mss 1460,nop,wscale 8,nop,nop,sackOK], length 0
22:10:23.068861 IP c-MYLOCALIP.64015 > MYREMOTEIP.8016: Flags [S], seq 1086832564, win 17520, options [mss 1460,nop,wscale 8,nop,nop,sackOK], length 0
22:10:28.813951 IP c-MYLOCALIP.64013 > MYREMOTEIP.8016: Flags [S], seq 486748091, win 17520, options [mss 1460,nop,wscale 8,nop,nop,sackOK], length 0
22:10:29.068276 IP c-MYLOCALIP.64015 > MYREMOTEIP.8016: Flags [S], seq 1086832564, win 17520, options [mss 1460,nop,wscale 8,nop,nop,sackOK], length 0
22:10:41.059752 IP c-MYLOCALIP.64044 > MYREMOTEIP.8016: Flags [S], seq 2201834519, win 17520, options [mss 1460,nop,wscale 8,nop,nop,sackOK], length 0
22:10:44.064410 IP c-MYLOCALIP.64044 > MYREMOTEIP.8016: Flags [S], seq 2201834519, win 17520, options [mss 1460,nop,wscale 8,nop,nop,sackOK], length 0
22:10:50.066253 IP c-MYLOCALIP.64044 > MYREMOTEIP.8016: Flags [S], seq 2201834519, win 17520, options [mss 1460,nop,wscale 8,nop,nop,sackOK], length 0
那我做错了什么?我只需要简单地托管未优化的Gatsby.js开发站点,就可以通过链接轻松地向我的合作伙伴展示我正在做的事情,它说它可以访问但正在超时。有什么建议么? :)
编辑:
我将其更改为:
Flags [.]
没有超时的情况下,只要连续发送length 0
,而不会指示即将加载或已完成加载。