我在digitalocean上有一个nodejs vps服务器,我正在尝试安装textbelt。
我的步骤: cd / srv / users / serverpilot / apps / sendsms / public / sms npm install
node server / app.js
以root身份安装make
sudo apt-get install build-essential
wget http://download.redis.io/redis-stable.tar.gz
tar xvzf redis-stable.tar.gz
cd redis-stable
请
sudo apt-get install mutt
现在我看到了这个错误 禁
您无权访问此服务器上的/ sms /。
此错误的可能原因包括:
.htaccess文件中的规则禁止该请求。 您请求的目录没有index.html或index.php文件。 文件或目录的权限不正确。 有关禁止请求的原因的详细信息,请参阅Apache错误日志:
/srv/users/SYSUSER/log/APPNAME/APPNAME_apache.error.log
请帮我完成这个设置。
答案 0 :(得分:0)
使用ServerPilot create a .htaccess file to proxy requests to the port your app is listening on运行非PHP应用程序,例如Node.js应用程序。
为此,您首先需要找出Node.js应用正在侦听的端口。然后,您可以创建.htaccess文件。
例如,如果您的Node.js应用程序正在侦听端口2345,则.htaccess文件将如下所示:
RewriteRule index.html http://localhost:2345/ [P]
RewriteRule (.*) http://localhost:2345/$1 [P]