简体   繁体   English

放置节点js应用程序的webapp文件的服务器目录

[英]Which server directory to place webapp files for a node js application

So I feel like this is a simple question that has just been evading me so hopefully I can get some help here. 所以我觉得这是一个简单的问题,一直在回避我,希望我能在这里得到一些帮助。 I have developed a nodejs webapp, the directory structure can be seen in the screenshot below. 我开发了一个nodejs webapp,目录结构可以在下面的屏幕截图中看到。 Eventually, this app will implement a mongodb and house a hefty size of audio files. 最终,该应用将实现mongodb并容纳大量音频文件。

I am using the inMotion Premier Support hosting plan (pretty basic) and when taking a look at the server through fileZilla I see there is a public_html directory. 我正在使用inMotion Premier Support托管计划(非常基本),并且通过fileZilla查看服务器时,我看到有一个public_html目录。

Do I put the whole contents of my webapp (everything in the screenshot) in the public_html directory? 是否将我的Web应用程序的全部内容(屏幕快照中的所有内容)都放在public_html目录中? I assumed that only the files that should be publicly accessible should go in there (only the contents of my apps public directory). 我假设只有应该可以公开访问的文件才应该进入那里(只有我的应用程序公共目录的内容)。 If that's the case where would I place the files that would be considered server-side (everything on the same level as app.js). 如果是这种情况,我将在哪里放置被视为服务器端的文件(所有文件都与app.js处于同一级别)。

Also my hosting service isn't dedicated or even virtual so I don't have access to the whole server just a certain number of directories. 另外,我的托管服务不是专用的,甚至不是虚拟的,因此我无法仅通过一定数量的目录访问整个服务器。

Any help is appreciated 任何帮助表示赞赏

I am currently working on a webapp. 我目前正在开发一个Webapp。 在此处输入图片说明

What you want is a VPS on inMotion, not a FTP server. 您想要的是inMotion上的VPS,而不是FTP服务器。 The public_html directory in these web hosting services is where you usually put static html files. 这些网络托管服务中的public_html目录通常是放置静态html文件的位置。 If you want to deploy node.js web apps, look at getting a server through VPS. 如果要部署node.js Web应用程序,请查看通过VPS获取服务器。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM